Be', se opti per il file di testo carichi tutti i nomi in un array e poi "tiri un numero" ad esempio cosi:
Se usi un db mysql puoi fare una SELECT ... ORDER BY RAND() LIMIT 1codice:$rand = rand(0, count($array)-1); echo $array["{$rand}"];
...anche se per le performance del db usare RAND() non e' mai una buona idea.
Scegli tu![]()