I have a simple script which produces a code for me on the homepage, the php I use is
srand(time()); $rand1 = (rand()%99999); $rand2 = chr(rand(ord("a"), ord("z"))); $date = date("dmY"); $code = "$rand1$rand2$date";
I then print the code using
<?php print "$code"; ?>
How can I retain this code and print it on any page that the user goes to? Even if they return to the homepage, how can I keep the code without it being replaced with a new one?
How could I also create a page to delete the code so the user can get a new code when they return to the homepage.
Any help would be great
Thanks in advance everyone