klavixs
Account Closed
- Impact
- 6
Warning to novices in php this is a pretty advanced script and should be used by a person who is very knowledge in php if you insist on useing it on a novice stage it's at your own risk.
This scrypt checks a user inputed password and then encrypts it and checks the db's version of the md5 enc to see it is correct
this next part is for user registration
This scrypt checks a user inputed password and then encrypts it and checks the db's version of the md5 enc to see it is correct
PHP:
//str is the inputed password the user gave
Function Encpass($str)
{
//this now encrypts the inputed password
md5($str);
//this checks the encrypted version of the inputed password
//to the databases stored version to see if it's correct
//change usrpass to whatever variable you use for the retrieved pass from db your checking
if (md5($str) == $usrpass)
{
//in your script check, if Cvalue equals 2 and it's a correct pass
$Cvalue = "2";
}
else
{
//but if its a 1 it's incorrect password
$Cvalue = "1";
}
}
//you should next check Cvalue to make sure it equals 2
//if you use this and like it a link to my website is appreciated but not required
// my website is http://onfiretechnologies.com and it's an arcade of flash games
// and has lots of cheat codes so use what ever relateing text you wish
this next part is for user registration
PHP:
//this part is for user registration to encrypt password in md5
//stpass is the inputed password to encrypt
Function CMd5Pass($stpass)
{
//npass is the new encrypted version of the orignal inputed pass
$Npass = md5($stpass)
}
//now to enter it in db. save the Npass variable to the db for password
//if you use this and like it a link to my website is appreciated but not required
// my website is http://onfiretechnologies.com and it's an arcade of flash games
// and has lots of cheat codes so use what ever relateing text you wish