Hallo glan,
srand(microtime()*1000);
Für PHP-Versionen >= 4.2.0 ist es nicht mehr notwendig, vorher srand() aufzurufen.
$zufallszahl = rand(1,100);
Es empfiehlt sich allerdings die Verwendung von mt_rand().
Schöne Grüße,
Johannes
Hallo glan,
srand(microtime()*1000);
Für PHP-Versionen >= 4.2.0 ist es nicht mehr notwendig, vorher srand() aufzurufen.
$zufallszahl = rand(1,100);
Es empfiehlt sich allerdings die Verwendung von mt_rand().
Schöne Grüße,
Johannes