|
Everthing above the horizontal rule is written in the head section of this page. The two random number generators are identical and act independently of each other. The script for them is in the body of the page.
Reload the page to see it change.
You can make an array to list images you wish to display at random. In my example above, I just added the following statement to the same script. I did not use an array. I just named the gifs "img0.gif", etc.
The script for Random number generators that don't produce a zero is similar to the one above. Both forms can be 'stacked' on the same page and work independently of each other:
Copyright © 2002 T R Landrum |