Real quick little function to get a random number using PHP.
$x = rand(1,100);
The variable $x will contain a random number between 1 and 100.
It’s rand(min, max) if you don’t want to use 1 and 100 as your limits.
Real quick little function to get a random number using PHP.
$x = rand(1,100);
The variable $x will contain a random number between 1 and 100.
It’s rand(min, max) if you don’t want to use 1 and 100 as your limits.
Be First to Comment