Changing pictures after some interval
Posted: Tue Feb 03, 2009 4:42 pm
Hi,
Is there a way to change a picture after some time, let's say 1 hour? I want to use the same place for many banners and cycle them. I'm thinking about using array of strings like this: "<a href="..."><img src="..." /></a>" and a for loop. I would use current system time for initializing counter variable(start_time) and change array element when current time is greater than start_time for some number. For 1h interval I guess it would be 60*60*1000. Is it possible to do it like this or is there a smarter way?
P.S. I need it on server side, won't use JavaScript.
Thanks in advance!
Is there a way to change a picture after some time, let's say 1 hour? I want to use the same place for many banners and cycle them. I'm thinking about using array of strings like this: "<a href="..."><img src="..." /></a>" and a for loop. I would use current system time for initializing counter variable(start_time) and change array element when current time is greater than start_time for some number. For 1h interval I guess it would be 60*60*1000. Is it possible to do it like this or is there a smarter way?
P.S. I need it on server side, won't use JavaScript.
Thanks in advance!