Generate a random integer with PHP
To generate a random integer with PHP, there is a function called rand( ) which does the job.
Depends on whether you want the generation number is within a certain range or not, rand( ) takes in 2 parameters:
rand(minimum of the range inclusive, maximum of the range inclusive) the 2 parameters are integers. If you do not input any parameter into the function, the generation range will be between 0 and RAND_MAX inclusive. Continue Reading →

