pugboy Posted May 15, 2008 Share Posted May 15, 2008 I have seen a few examples, but I have no clue to to adapt them for my usage... I just need to encrypt a string so no one can read it... How would I do that? Link to comment https://forums.phpfreaks.com/topic/105838-solved-encryption/ Share on other sites More sharing options...
BlueSkyIS Posted May 15, 2008 Share Posted May 15, 2008 http://www.google.com/search?client=safari&rls=en-us&q=php+encrypt+string&ie=UTF-8&oe=UTF-8 Link to comment https://forums.phpfreaks.com/topic/105838-solved-encryption/#findComment-542462 Share on other sites More sharing options...
pugboy Posted May 15, 2008 Author Share Posted May 15, 2008 I looked earlier. Found one that worked though. Thanks. Link to comment https://forums.phpfreaks.com/topic/105838-solved-encryption/#findComment-542469 Share on other sites More sharing options...
Guardian-Mage Posted May 15, 2008 Share Posted May 15, 2008 If you want to be able to decrypt it, consider using base64_encode(), maybe with a salt. If you just want to make a permanent encryption, say for a login system, I recommend using md5() with a salt. A salt is just for extra security. #md5 with a salt $salt = "texthere"; $encrypt = md5($salt . $password); #Here is my standard encryption $salt = "12 character salt here"; $encrypt = base64_encode(md5(base64_encode($salt.$password.$salt))) My encryption is overdone, but I would love to see someone crack it Link to comment https://forums.phpfreaks.com/topic/105838-solved-encryption/#findComment-542470 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.