jQuery EasySlider 1.7,自定义按钮不起作用
所以我对 jQuery 有点陌生,但我不明白为什么“下一步”按钮不起作用。 “上一个”按钮工作得很好。
您在这里看不到上一个按钮,因为没有上一张幻灯片,但我尝试启用文本选项,并且转到下一张幻灯片,效果很好。
我将相同的代码应用于“下一步”按钮,但它不起作用。有什么想法吗?
- 这是一个垂直幻灯片。单击小箭头。
这是似乎没有按预期方式工作的部分。
<span id="nextBtn"><a href="javascript:void(0);" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('down','','_img/downover.png',1)"><img src="_img/down.png" alt="Browse Down" name="down" width="53" height="35" hspace="130" border="0"></a></span>
这很奇怪,因为转换到上一张幻灯片的相同代码行可以完美地工作:
<span id="prevBtn"><a href="javascript:void(0);" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('up','','_img/upover.png',1)"><img src="_img/up.png" alt="Browse Up" hspace="130" name="up" width="53" height="35" border="0"></a></span>
So I'm kind of new to jQuery, but I can't see why the "Next" button doesn't work. The "Previous" button works just fine.
You cannot see the previous button here because there's no previous slide, but I have tried with enabling the text option and going to the next slide and it works just fine.
I'm applying the same code to the "next" button, but it just doesn't work. Any idea?
- It's a vertical slide. Click on the little arrow.
Here is the part which doesn't seem to work the way it's supposed to.
<span id="nextBtn"><a href="javascript:void(0);" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('down','','_img/downover.png',1)"><img src="_img/down.png" alt="Browse Down" name="down" width="53" height="35" hspace="130" border="0"></a></span>
This is odd, because the same lines of code for transition to the previous slide works perfectly:
<span id="prevBtn"><a href="javascript:void(0);" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('up','','_img/upover.png',1)"><img src="_img/up.png" alt="Browse Up" hspace="130" name="up" width="53" height="35" border="0"></a></span>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我认为您有重复的按钮,因为脚本会自动添加具有所需 id 的“上一个”和“下一个”跨度。
尝试删除上一个/下一个标签并让脚本创建它,或者设置
controlsShow: False
I think you have duplicated buttons, because the script automatically adds "previous" and "next" spans with the desired id.
Try removing your prev/next tags and let the script creating it, or set
controlsShow: False
注意:如果有人在垂直模式下仍然遇到多个滑块问题,请使用 1.5 版本。 1.7 似乎有一个错误,导致按钮无法正常工作。
ATTENTION: If anybody still has problem with multiple sliders in vertical mode, just use the 1.5 release. 1.7 seems to have a bug which prevents the buttons from working properly.