tongzhuang/WebRoot/js/slide.js
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
$(function(){
var $slides = $('.slide_pics li');
var len = $slides.length;
var nowli = 0;
var prevli = 0;
var $prev = $('.prev');
var $next = $('.next');
var ismove = false;
var timer = null;
$slides.not(':first').css({left:1000});
$slides.each(function(index, el) {
var $li = $('<li>');
if(index==0)
{
$li.addClass('active');
}
$li.appendTo($('.points'));
});
$points = $('.points li');
timer = setInterval(autoplay,4000);
$('.slide').mouseenter(function() {
clearInterval(timer);
});
$('.slide').mouseleave(function() {
timer = setInterval(autoplay,4000);
});
function autoplay(){
nowli++;
move();
$points.eq(nowli).addClass('active').siblings().removeClass('active');
}
$points.click(function(event) {
if(ismove)
{
return;
}
nowli = $(this).index();
if(nowli==prevli)
{
return;
}
$(this).addClass('active').siblings().removeClass('active');
move();
});
$prev.click(function() {
if(ismove)
{
return;
}
nowli--;
后面还有 70 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。