For user's password entered in a form before post, I simply just do
<?php
$pass=crypt($_POST['memberpwd']);
?>
But how can I later get the plaintext of that password in case the user may request ? Thank you.
EDIT: I found How can I encrypt password data in a database using PHP? and http://www.securityfocus.com/blogs/262, but I would just want to learn about this at a more basic level to understand the ways as to how it actually works.