Jump to content

Creating a "simple" fade-transitioning slideshow


Fmdpa

Recommended Posts

How do I create a JS slideshow with fade transition, and no buttons (unless they could be added with little extra code)? All of the slideshows I find have extremely long source code, or are just done with flash.

Link to comment
Share on other sites

OK, this is obviously not a hot topic. Let me give more details. It would be basically a cycling banner, WITH fade transitions. I assume I would start with an array:

function slideshow(){image= new Image ();image.src="images/photo1.jpg";image2= new Image ();image2.src="images/photo2.jpg";ss=new Array ();ss[0]="image.src";ss[1]="image2.src";}

Link to comment
Share on other sites

I think you'll find any solution has an "extremely long" source code. :)If you don't want animated transitions, then you can just use a timeout or interval to change the source of an image tag. However if you do want the fade it would be necessary to fiddle with the CSS opacity property, with the proper redundancy (i.e. filter() for IE).

Link to comment
Share on other sites

Where is there a good tutorial for what you explained (since w3school's tutorials really don't cover it)?
I think its more of a combination of techniques, which you could find individual examples of if you can't break down a complete example of fade/transitioning. Look up how to change the src of an image dynamically, try it out, then test out how timers work, then combine the two. If you're feeling saucy, with what you have learned between those two techniques, you should have a good foundation for how to add opacity.
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...