为啥jquery plusslider在google chrome中不起作用但在firefox中起作用

Posted

技术标签:

【中文标题】为啥jquery plusslider在google chrome中不起作用但在firefox中起作用【英文标题】:why jquery plusslider doesn't work in google chrome but works in firefox为什么jquery plusslider在google chrome中不起作用但在firefox中起作用 【发布时间】:2012-09-19 23:28:08 【问题描述】:

我正在使用 jquery plusslider,但问题是它在 Firefox 中工作正常,但滑块在谷歌浏览器中不起作用。同样,每当我将滑块类型用作推子时,滑块在两者中都可以正常工作,但我想将滑块类型用作滑块并且它不起作用。有什么问题。提前感谢您的任何帮助/建议和您的时间。谢谢你。。

$(document).ready(function() 
    $('#slider').plusSlider( 
        sliderEasing: 'easeInOutExpo', // Anything other than 'linear' and 'swing' requires the easing plugin
        paginationBefore: true,
        createArrows: true,
        width: 1920,
        height:580,
        sliderType: 'slider', // Choose whether the carousel is a 'slider' or a 'fader'
        displayTime: 5000
    );

【问题讨论】:

html代码放在这里。或者你错过了最后一个); 不,这不是问题......它在我的实际代码中关闭。很抱歉这个错误,但它没有效果。 @user108 发现问题 .... 在 chrome 但在 Firefox 中相同的 并且 left 的值会随着滑块的变化而变化。我该如何解决这个问题。 【参考方案1】:

Edit 它可以在 Chrome 中运行

$('#slider').plusSlider(
        sliderEasing: 'easeInOutExpo', // Anything other than 'linear' and 'swing' requires the easing plugin
        paginationThumbnails: true,
        sliderType: 'slider' // Choose whether the carousel is a 'slider' or a 'fader'
    );​

你错过了最后);

【讨论】:

认为我没有理解您的编辑,或者我遗漏了一些非常简单的东西。你能详细说明一下吗?我想你看到了一个丢失的 );在我的代码中。如果是这种情况,我想说它在我的实际代码中没有遗漏。所有的大括号都关闭了。 实际上,在我发布之前,我不会看到您的评论。所以现在工作还是不工作? 我会在我的 chrome 中尝试你的代码,它正在工作,但在控制台中查看是否有任何错误。你把 css all 也检查一下。

以上是关于为啥jquery plusslider在google chrome中不起作用但在firefox中起作用的主要内容,如果未能解决你的问题,请参考以下文章

为啥 Google 的 Closure 库不在他们的 CDN 上托管?

为啥在 google play store 上发布后 google 和 facebook 登录不起作用

为啥 Google 在前面加上 while(1);到他们的 JSON 响应?

为啥 Google 地图在我的 Android 应用程序中显示空白屏幕?

为啥 Google 的 ML 人脸检测工具包在 .process() 上崩溃

为啥我不能在 WordPress functions.php 中将多个 Google 字体排入队列?