View Full Version : Second Slide show

01-13-2011, 07:34 PM
1) Script Title: Second Slide Show

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex14/fadeinslideshow.htm

3) Describe problem: Following the instruction I want to create a second slide show. I read the hint that mayby this question is not supported.
But on the dynamicdrive site there is exactly for this a script like "var uniquevariable=new fadeSlideShow(options)"

My question is how to handle this command. I tried many versions but nothing helps. The first slideshow works perfect on http://www.haus-pelikan.de/html/vakantiehuis.html.

Now I want to place a (second) slidesohw (only showing pictures, without toggles) on http://www.haus-pelikan.de/.

What i have to replace or skip for this command-line above ?

Thank you - Dominik

01-15-2011, 05:58 AM
The code you copy and paste on the script page (http://www.dynamicdrive.com/dynamicindex14/fadeinslideshow.htm) actually already shows two slideshows running at the same time. The key is simply to call the initialization code again for each additional instance of the slideshow on your page, but with unique variable and ID names compared to the first instance:

var mygallery2=new fadeSlideShow({
wrapperid: "fadeshow2", //ID of blank DIV on page to house Slideshow
dimensions: [250, 180], //width/height of gallery in pixels. Should reflect dimensions of largest image
imagearray: [
["http://i26.tinypic.com/11l7ls0.jpg", "", "", "Nothing beats relaxing next to the pool when the weather is hot."],
["http://i29.tinypic.com/xp3hns.jpg", "http://en.wikipedia.org/wiki/Cave", "_new", "Some day I'd like to explore these caves!"],
["http://i31.tinypic.com/119w28m.jpg", "", "", "What a beautiful scene with everything changing colors."] //<--no trailing comma after very last image element!
displaymode: {type:'manual', pause:2500, cycles:0, wraparound:false},
persist: false, //remember last viewed slide and recall within same session?
fadeduration: 500, //transition duration (milliseconds)
descreveal: "always",
togglerid: "fadeshow2toggler"

The "fadeshow2" value would correspond to the ID of the DIV on the page that should house the 2nd slideshow:

<div id="fadeshow2"></div>