Super flexible light carousel plugin
###HTML template you can use:
<div class="carousel-wrapper" id="products">
<ul class="carousel-inner clearfix">
<li class="item">
<p class="item-info">Lorem ipsum</p>
</li>
<li class="item">
<p class="item-info">Lorem ipsum</p>
</li>
</ul>
<a href="#" class="carousel-left"></a>
<a href="#" class="carousel-right"></a>
</div>
.carousel-wrapper
- Element for wrapping list with carousel items and navigation buttons..carousel-inner
- List with items..item
- Class for items..carousel-left
and.carousel-right
- Left and right buttons for navigation.
###Creating carousel in JavaScript:
//Initializing carousel
if (document.getElementById('products')) {
var productsCarousel = new Carousel('products', 3);
}
'products'
- Id of wrapper element.3
- number of visible items.if (document.getElementById('products'))
- checking if such element exist.
###CSS
You can delete demo styles which placed under /*Demo styles*/
comment and style carousel yourself.