Ok. thats obvious that certain must store hashed password within the database but just in case a person doesn't takes note of the password and wish to retrieve it back, then clearly the consumer wont enjoy having the hashed password. When the password is hashed with md5 or additional like salt and sha1 then how you can retrieve back the password.

There's only one simple answer: You can't.

Well, theoretically you can, but it might take a long time per password if they're lengthy enough. In the end, that's the purpose of hashing passwords to begin with: to create the information effectively useless for an attacker (or at best safeguard anyone's plaintext password, that is sensitive data.)

Simply have the website send a "improve your password" email that contains a hyperlink to some page where that user can alter his/her password. This is the way best sites handle this dilemma.

This really is intended to be intractable. Thus, you typically need to provide a way of resetting it. Delivering a unique connect to anyone's email is typical, although it reduces your security to that particular from the email account.

See Forgot Password: what is the best method of implementing a forgot password function? .

The safety of hashing rather than encrypting the password is you cannot reverse a hash. Should you could unhash the password and provide the consumer their plain text password, then any hacker can turn back hashed password you utilize for registration and register and "dehash" it to obtain the user's password.
This can be a feature, not really a bug.

hashing itself means "can't be retrieved back".

If your user cannot remember their password, they do not need that one without a doubt.
Just create another random one and send them.
Not really a large deal.

yes..you can didn't remember his/her password..the great practice while using the hashed password is always to result in the user type the e-mail address from the account whose password he/she wish to totally reset then your system will totally reset the customers password with another produced password. The MD5 like hashed password is nearly impossible to retrieve the initial password in the hashed one

Always beware sites that may e-mail the password you utilize. Which means passwords is definitely seen by anybody who can access the password database, that is especially harmful should you reuse passwords.

For password resetting, I suggest using 'safe questions' with solutions which are also encoded.

It behooves all individuals who operate websites to have their clients reasonably protected from cyber-terrorist.