1

我有一个 jQuery 插件,超大 3.2.7 在 Chrome 和 Firefox 中工作,但在 IE8 中不起作用。图片加载不出来。

以下是控制台中显示的错误。

SCRIPT5007: Unable to get value of the property 'thumb': object is null or undefined 
supersized.js?ver=3.4, line 13 character 1126

Javascript代码:

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script src="assets/js/supersized.js?ver=3.4"></script>
<script src="assets/js/supersized.shutter.js?ver=3.4"></script>
<script src="assets/js/easing.js"></script>
<script>

    jQuery(function($){

        jQuery.supersized({ 
            slide_interval: 5000,
            transition: 'fade',
            transition_speed: 1000,
            new_window: 0,
            horizontal_center: 1,
            progress_bar: 0,
            mouse_scrub: 0,                             
            slides:[

                {image: 'http://localhost/assets/images/city-at-night.jpg', title: '<h1>Discover More Possibilities...</h1><h2>At Lorem Ipsum, we fulfil your ideas'},
                {image: 'http://localhost/assets/images/modern-skyscraper.jpg', title: '<h1>Explore Our Capabilities</h1><h2>Lorem Ipsum Dolor Sit Amet'},
            ]

        });
    });

</script>
<script src="assets/js/scripts.js"></script>

任何帮助,将不胜感激!

4

1 回答 1

9

尝试删除幻灯片数组中的最后一个逗号

slides:[

            {image: 'http://localhost/assets/images/city-at-night.jpg', title: '<h1>Discover More Possibilities...</h1><h2>At Lorem Ipsum, we fulfil your ideas'},
            {image: 'http://localhost/assets/images/modern-skyscraper.jpg', title: '<h1>Explore Our Capabilities</h1><h2>Lorem Ipsum Dolor Sit Amet'}
        ]
于 2012-07-05T02:04:34.257 回答