Pages

Wednesday, March 5, 2014

Tutorial Random String from Pre-Determined Characters

<?php
$string = "abcdwxyz456789";
for($i=0;$i<25;$i++){
   $pos = rand(0,13);
   $str .= $string{$pos};
}
echo $str;
?>

No comments:

Post a Comment