Hey everybody I want to let you know that I have undertaken the grueling task of getting the heck away from WordPress. I was so sick of the problems and updates I had to do all the time. I am now using my ezbloo system and I am integrating all my old posts into the new system. It sucks, but in the end, I will save bundles of time. I needed to keep things simple and that is why I created ezbloo. I'll have more on this later for you guys after I am done with the total integration of my old posts here. So if you are looking for a post and need it faster, shoot me an email and I will make it a priority. [email protected]

Sometimes we need to encrypt a password hash in php before inserting it into the database. This should not be used for user password but maybe an additional password. Either way it is fun to work with. The code below will reveal this information.

$1$aGwdyCbv$dwOWTv3mGDXIH0tHK7Ova1 hash

<?php $passwordtohash = 'mypassword'; $hash = crypt($passwordtohash); echo $hash; echo $passwordtohas; ?>

Explaining the Crypt Code and Process

The php variable of $pass is holding within it "hash". We then take the variable $passwordtohash and put the crypt function on it and store it in another variable called $hash. We then echo out both the $hash and the $passwordtohash to see what they look like.

Uses of PHP Crypt

Remember there is no way to decrypt the algorithm.  So this would only be good if you wanted a use to enter something to match something that is encrypted like a password hash. You would also want to encrypt your password with something like  
$encrypted=sha1(md5($passwordtohash));
More info on php crypt