Ali Asghar Toraby Parizy wrote:
I need a hash function to build a Unique serial number by mixing a request
code and a user name
request codes are strings like this: They are literally HEX codes of MAC mac
i want to create a function that mix together this request code with user
name that user entered and create new serial number.
What implications i have to satisfy to create such hash function in php?
Thanks for any suggestion
How about using sha1 to hash your string. If the data is unique then the
hash will be unique as well.
$string = $request_code.$user_name;
$hash = sha1($string);
Jeder hat soviel Recht, wie er Macht hat.
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php