I have the following code in file index.php:
include('db_connect.php'); //Here's the script that provides mysql connection to a database
$a = round(rand(1,100));
$b = round(rand(160,202));
$c = round(rand(50,110));
$d = round(rand(1,99999));
$sql = "INSERT INTO sInstance (p1,p2,p3,p4) VALUES ('".$a."','".$b."','".$c."','".$d."')";
$result = mysql_query($sql) or die(mysql_error());
Obviously, it randomly generates values and inserts them as a record into MyISAM database table sInstance.
The problem: after ~1000 records are generated & inserted, it's almost impossible to generate new records (with unique sets of values). Every new record is a clone of some old one (with the same p1-p2-p3-p4 values).
The question: How to avoid this and make php generate unique records?
The clue: It is a server-side problem with PHP, probably it somehow caches values that are set with the help of RAND() function. The problem is not connected neither to browser, nor to mysql itself.