Fx.ElementSwap is a Slide Show class that will swap between any element using Fx.MorphElement to create the slide show effects.
Inherits methods, properties, options and events from ElementSwap.
var myElSwap = new Fx.ElementSwap(elements[, options]);
See ElementSwap for all available events.
var elSwap = new ElementSwap('.div_swap');
#el1 {background-color:#f00;}
#el2 {background-color:#0f0;}
#el3 {background-color:#00f;}
.div_swap {
position:absolute;
top:0px;
width:300px;
height:300px;
z-index:0;
display:none;
}
.active { display:block; z-index:1;}
.elementSwap {
position:relative;
width:300px;
height:300px;
margin-left:auto;
margin-right:auto;
overflow:hidden;
}
<div id="el1" class="div_swap"><p>DIV 1</p></div> <div id="el2" class="div_swap"><p>DIV 2</p></div> <div id="el3" class="div_swap"><p>DIV 3</p></div>
A note on comments here: These comments are moderated. No comments will show up until they are approved. Comments that are not productive (i.e. inflammatory, rude, etc) will not be approved.
Found a bug in this plugin? Please report it this repository's Github Issues.
blog comments powered by Disqus