Rotating Banner with links?

Soldato
Joined
25 Sep 2003
Posts
3,747
Location
Manchester
I'm looking for a way to put banners (not ads) on one of my websites which will rotate randomly each time the user clicks a page link. That banner is then clickable for the user to be able to view the advertised item.

Ive been looking around for a way to do it but not come up with much so I've turned to here cos I know someone will know a way!
 
I got a PHP script from somewhere that when used displays a random image from the folder it is sat in.

Looking at the code I am not sure how it can be tweaked to create the correct link that goes with it.
 
Sounds perfect minus the non ability to link. :( I have just found one which works fine but means I have to manually add the new image to its list and also increase the rnd numbers etc for every page which isn't too practical. Be nice to just have a script that works like the one you're using.
 
Last edited:
www.tob3z.com/stuff/sig/rotate.php

steal that if you like. Chuck it in a folder with some images and it should work. Not too sure I get what you mean by links though. I wouldn't know how to do individual links.

Since he is rotating banners, he wants people to be able to click through to the website the banner is advertising.

Could you link to the .php file on its own? For whatever reason, your link wont give me the code - just gibberish. [I think my Ubuntu is accessing the image, rather than the php file itself.]
 
Last edited:
like a advertising system? So when I click the banner I go to google.com... when I refresh the page a banner for ask.com is shown and takes me to said website?
 
rather than using php to randomise the image, you'd use php to randomise the html that is used to display the image/link. :)
 
Back
Top Bottom