Generate Random String or Random Number in PHP

You can generate the random number or random string using rand() function. rand() function returns a number based on its range. The following script will generate the random number or random string at required length.

Script to Generate Random Number / Random String