Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试查看此图像库的 javascript 代码是否可以作为单击图像以查看下一步的选项。目前,它仅设置为通过单击下一个/上一个按钮转到下一个图像。有什么想法吗?
来源: http ://threepointmotors.com/lytebox.js
示例: http ://threepointmotors.com/NewsandEvents/CurrentNews/2012/smartElectricDriveCollection/tabid/226/Default.aspx
我看到你的页面已经包含了 jQuery 库,所以这应该是一件容易的事。
$('body').on('click', '#lbImage', function() { //when display image is clicked if ($('#lbNext2_Off').is(':hidden')) //check if it isn't the last image myLytebox.changeContent(myLytebox.activeSlide + 1); //move to next image });