How to change the image source in magento

advertisements

Please tell me how to change the image source in magento dynamically.say I want that after every 10 seconds I want to change the source of image. now I have define a static block which contain image src with id banner.. now my question is where should I define for changing the image source and how to change the source.


I would suggest looking into a jQuery based image rotator. There are some simple examples out there such as this one:

http://burnmind.com/tutorials/how-to-create-a-simple-automatic-image-rotator-using-jquery

Also be careful not to cause conflicts with jQuery and Prototype. You can use this method to avoid this from happening.