Flexslider infinite loop is not working

谁说我不能喝 提交于 2019-12-05 21:04:33

Here is how to do it while keeping the itemWidth property:

jQuery('.flexslider').flexslider({
        animation: "slide",
        animationLoop: false,
        minItems: 4,
        maxItems: 6,
        itemWidth: 210,
        itemMargin:5,
        controlNav: false,
        end : function(slider){
                jQuery('.flexslider .slides li').each(function(){
                    slider.addSlide('<li>'+jQuery(this).context.innerHTML+'</li>', slider.count);
                    jQuery('.flexslider .slides').append('<li>'+jQuery(this).context.innerHTML+'</li>');
                });
            }

      });

The main thing is to use the jQuery function in the end: property. I think animationLoop also needs to be set to false. This allows for an infinite loop carousel. Here is where I found this.

if you remove string

itemWidth: 234,

animationLoop will be work

At least one thing set wrong is you have

animationLoop: false, 

it should be:

animationLoop: true, 
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!