<Updated>
Here's what I have put in sub html_home. I am using the num_records mod by Eliot, www.gossamer-threads.com/scripts/forum/resources/Forum12/HTML/001547.html , with a slight modification of return $count instead of print $count.
srand;
$find = 0; $rand = int (rand ($count + 0.5)); ($rand == $count) and ($rand--);
and then in the body of the page (not in a print statement):
It does indeed get and print out a random record, but clicking on the link generates an internal server error I think because I'm not passing the right information (the full URL that results is /cgi-bin/db.cgi?db=default&uid=default&nh=-1&mh=1). A little help?
[This message has been edited by oldmoney (edited December 22, 1999).]
Here's what I have put in sub html_home. I am using the num_records mod by Eliot, www.gossamer-threads.com/scripts/forum/resources/Forum12/HTML/001547.html , with a slight modification of return $count instead of print $count.
Code:
$count = num_records; srand;
$find = 0; $rand = int (rand ($count + 0.5)); ($rand == $count) and ($rand--);
and then in the body of the page (not in a print statement):
Code:
&html_record(&get_record($rand));It does indeed get and print out a random record, but clicking on the link generates an internal server error I think because I'm not passing the right information (the full URL that results is /cgi-bin/db.cgi?db=default&uid=default&nh=-1&mh=1). A little help?
[This message has been edited by oldmoney (edited December 22, 1999).]