random number in php 6 digit code example
Example 1: php random number
// $min and $max are optional
rand($min,$max);
Example 2: php random integer
echo random_int(0,50);
Example 3: php random 5 digit number
$limit = 3;
echo random_int(10 ** ($limit - 1), (10 ** $limit) - 1);