Results 1 to 3 of 3
search results to be displayed in new page Forum: PHP ForumReplies: 1
Labels not displayed Forum: CSS ForumReplies: 0
profile layout problems..alternate browsers Forum: Myspace ForumReplies: 0
Alternate for applet menu Forum: Website Scripts ForumReplies: 0
10-01-2007, 01:30 PM #1
Alternate between images being displayed
I want to have 2 or more images that round robin rotate. When someone visits the image image #1 is displayed, the next time someone visits the image #2 is displayed and so on.
Is there a simple way to rotate between images?
05-08-2008, 03:42 PM #2
Re: Alternate between images being displayed
if you're just looking for a quick script to randomize b/w two images every time the page is refreshed, there are many resources online that will provide code for that...just as long as you reference the author in a comment in the head of your code. here's one i'm currently using for an architecture website under construction (excuse the pun).
Keep this notice intact please
var myimages=new Array()
//specify random images below. You can have as many as you wish
document.write('<img src="'+myimages[ry]+'" border=0>')
for this to work, simply insert this script with the comment in the table cell you would like to have the image appear in, and every time the page is refreshed the image will change randomly among the list of images in the script. this one is very basic as far as i can tell, and is just one way to get the job done.
06-03-2008, 11:16 AM #3