Quote:
Originally Posted by AbyssUnderground
You could have a separate page for each and then some basic php pr javascript to go to one of the random pages. PHP would be better since it works on all computers, but with javascript it would have to be enabled. Here is the PHP I would use.
random.php
PHP Code:
<?php
// 1,4 indicates a number between 1 and 4 will generate on load, edit as necessary with the number of pages $rand = rand(1,4);
// this redirects your browser to the appropriate page based on the random number (in theory!) header("Location: testimonial".$rand.".htm");
// name pages as "testimonial1.htm" and "testimonial2.htm" etc, with a progressing number // as you make new pages. Remember to edit the random number to the number of pages // you have made testimonials for
?>
The script is untested but should work.
|
I had a think about this at work, although I am not up to spead with php, got a book, but its not light reading...
anyway, I was thinking of making a basic page that someone can enter details and storing this as an xml file (and appends to the file), then I could generate a random quote from the xml file, would this work? not looking for links to anything just a testimonial really.
Sorry forgot to say, the testimonials are supposed to be vied in one page that has other info on it.
ik