in reply to Is this use of crypt() appropriate?

Another post by me, I keep re-reading the posts above and thinking of new ways to approach this. I'll explain how I am doing my login management at the moment: When someone signs up their password is encrypted in a MySQL database, when they login their password is encrypted again and stored in a cookie, each request checks that the password in the cookie matches that in the database.

The theory above using the below code is the one that appeals to me the most
my @chars=(a..z,A..Z,0..9,'.','/'); my $salt= $chars[rand(@chars)] . $chars[rand(@chars)];

The only problem with this is that it will encrypt the password randomly, so I would need to decrypt it in other areas of the script and store the mysql password in plain text, rather than also encrypted.

My understanding of crypt() is fairly limited and I have learnt a fair ammount from the posts above, I would greatly appreciate it if anyone could provide some advice based on what I have posted here..
Thanks very much