Using <div>s as slides instead of images in ImageFlow Slider

714 Views Asked by At

I am using ImageFlow for making an image slider. I want to use <div>s instead of images for slides. How can I do it?

1

There are 1 best solutions below

3
gersande On

I checked out your link from the comments - you write that you can't edit the actual code to wrap a div around each individual img. Are you trying to change the way the gallery works so that instead of inputing img you can simply insert divs and have the slider js still work?

I took the HTML below from the link you posted earlier :

<div id="myImageFlow" class="imageflow" style="visibility: visible; height: 517px; "><img src="img/9_comtech_o.jpg" id="id11" height="360" width="300" longdesc="img/img11.png" alt="img11"><img src="img/8_psabuilding.jpg" id="id9" height="360" width="300" longdesc="img/img9.png" alt="img9"><img src="img/7_mbc.jpg" id="id7" height="360" width="300" longdesc="img/img7.png" alt="img7"><img src="img/5_lighthouse.jpg" id="id5" height="360" width="300" longdesc="img/img5.png" alt="img5"><img src="img/2_harbourfront3.jpg" id="id3" height="360" width="300" longdesc="img/img3.png" alt="img3"><img src="img/1_bankofamerica.jpg" id="id1" height="360" width="300" longdesc="img/img1.png" alt="img1">

This is what I would do if I wanted the js to accept divs instead of imgs:

<div id="id1"><img id="id1" /></div> 

You may need to change the way the CSS/js reacts to #myImageFlow.