Guest oldboy Posted June 4, 2007 Share Posted June 4, 2007 Over a month ago i requested some advice on how to get rotating images on the main page, but no reply so i try again. I have searched the forum and google and i cant find any easy way to have images rotate. There most be an easy way to do this via a php script. Any suggestions? Quote Link to comment Share on other sites More sharing options...
Robsta Posted June 4, 2007 Share Posted June 4, 2007 Over a month ago i requested some advice on how to get rotating images on the main page, but no reply so i try again. I have searched the forum and google and i cant find any easy way to have images rotate. There most be an easy way to do this via a php script. Any suggestions? Rotating as in scrolling? which images? Quote Link to comment Share on other sites More sharing options...
Guest Posted June 4, 2007 Share Posted June 4, 2007 openads? Quote Link to comment Share on other sites More sharing options...
Homar Posted June 4, 2007 Share Posted June 4, 2007 I'd use javascript to create a rotating advertisement. Do a google search for "DHTML Banner Ad Rotator". You should then add a new div to YOUR_SKIN/styleTemplates/global/index.tpl I'd add the div beneath the div which contains the Categories tag. Then simply incorporate the DHTML Banner Ad script (or some other script) into that div. You'll of course need to upload the banner ad script to your server, ensuring the links in the index.tpl file point to the right directory where you'll be keeping that banner ad rotator. Hope this helps! Quote Link to comment Share on other sites More sharing options...
markscarts Posted June 5, 2007 Share Posted June 5, 2007 You can rotate images with javascript or with a php script. Don't give up after failing to integrate the one script. Here is an example of rotating images with java script: http://www.allstarbowling.com/ Look at the sites in Show Off forum, you will see some that use js and some that use php scripts I believe. There is a mod with total CubeCart integration of js slideshow, configurable in Admin Control panel, I know because I wrote it. Also, if you want to hard code some js image script this is not difficult to do and there is a thread here somewhere about it, search for javascript slideshow, or just slideshow, you are bound to be able to find it somehow. Quote Link to comment Share on other sites More sharing options...
Guest Rikki Posted June 5, 2007 Share Posted June 5, 2007 Im working on our company site at the moment and we have a JPG rotator in flash running: http://www.xsmotorsport.co.uk/shop/ Would that be what you are looking for? Rikki Quote Link to comment Share on other sites More sharing options...
Guest xceejayx Posted June 5, 2007 Share Posted June 5, 2007 this might be what you're looking for...? <script language=JavaScript> var img_width = "468"; var img_height = "60"; var img_title = "Click Here"; var ad=new Array() //insert here your images src ad[0]='http://IMAGE1.jpg'; ad[1]='http://IMAGE2.jpg'; ad[2]='http://IMAGE3.jpg'; ad[3]='http://IMAGE4.jpg'; ad[4]='http://IMAGE5.jpg'; var links=new Array() //insert here your links links[0]='http://LINK1.com'; links[1]='http://LINK2.com'; links[2]='http://LINK3.com'; links[3]='http://LINK4.com'; links[4]='http://LINK5.com'; var xy=Math.floor(Math.random()*ad.length); document.write('<a href="'+links[xy]+'" target="_blank"><img src="'+ad[xy]+'" width="'+img_width+'" height="'+img_height+'" alt="'+img_title+'"></a>'); </SCRIPT> you could probably remove the links bit if you just wanted the images without links... i dunno Quote Link to comment Share on other sites More sharing options...
Guest hardnut33 Posted June 5, 2007 Share Posted June 5, 2007 have you got this code on your site ceejay? your ruby site is great. a real old skool style tattooist theme. Oldboy, I have a link on how to create a js slideshow, im just unsure if i'm allowed to post it here..PM me if you want the link Quote Link to comment Share on other sites More sharing options...
Guest xceejayx Posted June 5, 2007 Share Posted June 5, 2007 Thanks hardnut No i don't have it on my site anymore, i used to use it when i was using an affilliate program, but decided it wasn't earning me enough cash! Quote Link to comment Share on other sites More sharing options...
markscarts Posted June 6, 2007 Share Posted June 6, 2007 harrdnut, your link will probably be fine if it is a javscript tutorial about slideshows. If it is strictly educational, it would benefit the members. The link restrictions here are meant to remove advertising by third-party CubeCart service providers, and to prevent anything even remotely approaching forum spamming by such. Quote Link to comment Share on other sites More sharing options...
Guest LewisSellers Posted June 10, 2007 Share Posted June 10, 2007 Hi, Rikki, the example you've given, is exactly what I want on my site, could you send me a PM or reply on here on where I can get it from and how to install it. That would be great! Thanks Lewis Quote Link to comment Share on other sites More sharing options...
Guest oldboy Posted June 10, 2007 Share Posted June 10, 2007 Thanks for all interesting tips, they all look really nice, but im actually looking for a simple php script to rotate images on every page load. No slide show, ads, scrolling, java or Flash, just a script that will rotate images from a directory. The point is to have different images to show up for a returnign visitor. Also if possible to have each image to point to a specific link. Quote Link to comment Share on other sites More sharing options...
Guest xceejayx Posted June 15, 2007 Share Posted June 15, 2007 Thanks for all interesting tips, they all look really nice, but im actually looking for a simple php script to rotate images on every page load. No slide show, ads, scrolling, java or Flash, just a script that will rotate images from a directory. The point is to have different images to show up for a returnign visitor. Also if possible to have each image to point to a specific link. the code i gave can do exactly that not php but still simple Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.