【问题标题】:Jssor slider looks flickering on scroll? how to stop reloading of images?Jssor 滑块在滚动时看起来闪烁?如何停止重新加载图像?
【发布时间】:2015-04-21 05:07:45
【问题描述】:

您好,当我返回图像时,我的图像正在重新加载,并且 jssor 滑块看起来闪烁……我还想在缩略图单击时添加淡入淡出效果。有什么解决办法吗???谢谢你的帮助。 我的jquery代码如下:

 $(document).ready(function () {
//$('#slider1_container').css('background',url(SITE_URL+'ui/admin/images/loading.gif'));
        $(window).unbind("mousewheel");
        var _SlideshowTransitions = [
            //Fade
            { $Duration: 1200, $Opacity: 2 }
            ];
            var options = {
//                $AutoPlay: true, 
                $Duration: 1200, $Opacity: 2,                                  //[Optional] The way (0 parellel, 1 recursive, default value is 1) to search UI components (slides container, loading screen, navigator container, arrow navigator container, thumbnail navigator container etc).

                $ThumbnailNavigatorOptions: {
                    $Class: $JssorThumbnailNavigator$,                                  //[Required] Class to create thumbnail navigator instance
//                    $ChanceToShow: 2,                                                   //[Required] 0 Never, 1 Mouse Over, 2 Always
                    $Loop: 0,
                    $ActionMode: 1,                                                     //[Optional] 0 None, 1 act by click, 2 act by mouse hover, 3 both, default value is 1
                    $Rows: 2,                                                          //[Optional] Specify lanes to arrange thumbnails, default value is 1
                    $SpacingX: 3,                                                      //[Optional] Horizontal space between each thumbnail in pixel, default value is 0
                    $SpacingY: 4,                                                      //[Optional] Vertical space between each thumbnail in pixel, default value is 0
                    $Cols: 6,                                                   //[Optional] Number of pieces to display, default value is 1
                    $Align: 156,                                               //[Optional] The offset position to park thumbnail
                    $Orientation: 2,                            //[Optional] The offset position to park thumbnail,

                    $ArrowNavigatorOptions: {
                        $Class: $JssorArrowNavigator$,              //[Requried] Class to create arrow navigator instance
                        $ChanceToShow: 2                               //[Required] 0 Never, 1 Mouse Over, 2 Always
                    }
                },
                $SlideshowOptions: {                                //[Optional] Options to specify and enable slideshow or not
                    $Class: $JssorSlideshowRunner$, 
                                                                    //[Required] Class to create instance of slideshow
                    $Transitions: _SlideshowTransitions,            //[Required] An array of slideshow transitions to play slideshow
                    $TransitionsOrder: 1,                           //[Optional] The way to choose transition to play slide, 1 Sequence, 0 Random
                    $ShowLink: true                                    //[Optional] Whether to bring slide link on top of the slider when slideshow is running, default value is false
                }
            };

            var jssor_slider1 = new $JssorSlider$("slider1_container", options);

            //responsive code begin
            //you can remove responsive code if you don't want the slider scales while window resizes

//            ScaleSlider();

//            $(window).bind("load", ScaleSlider);
//            $(window).bind("resize", ScaleSlider);
//            $(window).bind("orientationchange", ScaleSlider);
            //responsive code end
    });

</script>

网址:http://www.jssor.com/demos/image-gallery-with-vertical-thumbnail.html

【问题讨论】:

    标签: jquery slider jssor


    【解决方案1】:

    这取决于您的服务器设置。 请为您的图像启用客户端缓存(您的服务器上的设置之一/或由您的服务器端程序控制)。

    【讨论】:

    • 点击缩略图时的淡入效果如何?
    • 此功能尚未实现。目前,所有按需导航请求都会导致向左向右滑动效果。
    猜你喜欢
    • 1970-01-01
    • 2017-07-19
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多