Forum Moderators: open

Message Too Old, No Replies

WANTED Picture change with each refresh

WANTED Picture change with each refresh

         

geefunk

7:23 pm on Jan 25, 2005 (gmt 0)



I want to make an "adopt a pet" graphic where the picture changes with each refresh.. not like a slideshow where it is timed, but only when the page is refreshed or you go else where in the site and then come back to the main page and the picture is different

I'm not even sure what script I would use to make it so someone please help me!

PatrickDeese

7:38 pm on Jan 25, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I would do a search for "banner rotator script" on a site like hotscripts or similar - chances are you can adapt the scripts to show your pet images.

webboy1

9:41 pm on Jan 25, 2005 (gmt 0)

10+ Year Member



Not sure if you have found a solution for this yet, but if it is of any help, we use a random script written in ASP. It is only a couple of lines .... so not to complicated.

It basically randomly pics a number from the values you give it and then picks a picture depending on which number is chosen.

It is completely random, so the picture may not change when you refresh the page (i.e. it may choose the same picture twice) but the more pictures you have the less likely this will happen.

I can give you a copy of the script if you like?

jatar_k

9:44 pm on Jan 25, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Welcome to WebmasterWorld geefunk,

you could do it with javascript or php as well, pretty much anything.

What languages do you have available to you with your host?

stef25

1:47 pm on Jan 26, 2005 (gmt 0)

10+ Year Member



a list apart has an article called "a better image rotator", which looks extremely simple to implement

however, even tho i have basic experience with php, i cannot get this script to work.

maybe you have better luck - its really simple