Hi,
Right now I am working on creating a string of 5 random letters. I have already created the script, it does create a unique random letter but it repeats it 5 times. Here is what I have so far:
It diplays 5 of the same letters, I want unique letters.
Right now I am working on creating a string of 5 random letters. I have already created the script, it does create a unique random letter but it repeats it 5 times. Here is what I have so far:
Code:
<?php
srand();
$random=chr(rand(ord("A"),ord("Z")));
$string="";
for ($i=1;$i<6;$i++) {
$string .= $random;
}
echo $string;
?>
Comment