Skip to content

Instantly share code, notes, and snippets.

@AndrewChamp
Created September 29, 2015 02:50
Show Gist options
  • Save AndrewChamp/08b2e7b7d790f74bb101 to your computer and use it in GitHub Desktop.
Save AndrewChamp/08b2e7b7d790f74bb101 to your computer and use it in GitHub Desktop.
Simple Hashing
<?php
function hasher($password, $salt){
$result = base64_encode(hash('md5', $password.$salt));
$result = substr($result, 5, -5);
return strrev($result);
}
//Example
print hasher('myPassword', time());
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment