[This code is written in php,butt this can be used in any other desired language using the same function.]
function get_hash(){
$string = '0123456789abcdefghijklmnopqrstuvyxz';
$hash = '';
for ($i = 0; $i < 5; $i++){
$rand = rand(0, (34 - $i));
$hash .= $string[$rand];
$string = str_replace($string[$rand], '', $string);
}
return $hash;
}
No comments:
Post a Comment