猫头鹰轮播加载问题

时间:2019-04-25 20:00:36

标签: javascript jquery html5 owl-carousel-2

猫头鹰轮播加载问题我正在使用jquery插件owl-carousel我根据指南设置了轮播,但它显示了我的猫头鹰轮播加载(向dom owl-loading添加了类)。我添加了自定义样式或javascript代码。请帮助我解决这个问题。预先感谢。

html

                        <div id="owl" class="owl-carousel owl-theme partners_slider">

                            <!-- Partner Item -->
                            <div class="owl-item partner_item"><img src="./assets/img/client/partner_1.png" alt=""></div>

                            <!-- Partner Item -->
                            <div class="owl-item partner_item"><img src="./assets/img/client/partner_2.png" alt=""></div>

                            <!-- Partner Item -->
                            <div class="owl-item partner_item"><img src="./assets/img/client/partner_3.png" alt=""></div>

                            <!-- Partner Item -->
                            <div class="owl-item partner_item"><img src="./assets/img/client/partner_4.png" alt=""></div>

                            <!-- Partner Item -->
                            <div class="owl-item partner_item"><img src="./assets/img/client/partner_5.png" alt=""></div>

                            <!-- Partner Item -->
                            <div class="owl-item partner_item"><img src="./assets/img/client/partner_6.png" alt=""></div>

                        </div>
                    </div>

js

    <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.0/jquery.js"></script>

    <script src="./assets/js/owl.carousel.js"></script>
    <script>
        $(window).on('load',function(){
            $('#owl').owlCarousel(
            {
                autoplay:true,
                smartSpeed:1200,
                lazyLoad : true,
                nav:false,
                dots:false,
                responsive:
                {
                    0:
                    {
                        items:1
                    },
                    480:
                    {
                        items:2
                    },
                    720:
                    {
                        items:3
                    },
                    991:
                    {
                        items:4
                    },
                    1199:
                    {
                        items:6
                    }
                }
            });

});

    </script>

0 个答案:

没有答案