JCarousel Lite and adding more images to a dynamically built list
I've integrated jcarousel lite into a magento site for a product image gallery.
The page dynamically builds a list (via magento) of the necessary images.
However, as soon as jcarousel lite is added to the page, additional < li > can be seen in the < ul > part of the page.
In summary: without jcarousel lite - correct number of images in the with jcarousel lite - additional items in the
here's how jcarousel lite is being invoked on the page in question:
<script type="text/javascript">
jQuery(function() {
jQuery(".more-views").jCarouselLite({
btnNext: ".next",
visible: 1,
speed: 500,
btnPrev: ".prev"
});
});
</script>
any hints o开发者_如何学运维n why this is occuring?
I believe that's the way jCarouselLite works (and to that end, almost all 'carousel' or 'slider' types of plugins) -- ie, they duplicate the items that are 'out of view' so that you get a smooth transition as the user cycles through the items. This is normal functionality.
精彩评论