$(function(){
$("ul li:lt(5)").clone().appendTo("ul");
var $width = $("ul li:lt(5)").width() * 4;
var currIndex = 0;
$("#next").click(function(){
if(currIndex == 2){
currIndex = 0;
$("ul").css("left",0);
}
currIndex++;
$("ul").stop().animate({left:$width * currIndex * -1},500);
});
$("#prev").click(function(){
if(currIndex == 0){
currIndex = 2;
$("ul").css("left",2 * $width * -1);
}
currIndex--;
$("ul").stop().animate({left:$width * currIndex * -1},500);
});
$("ul>li").hover(function(){
$(this).children().eq(1).stop().animate({top:0},400);
},function(){
$(this).children().eq(1).stop().animate({top:240},400);
});
});

最新文章

  1. C# TransactionScope 使用
  2. Leetcode: Find Leaves of Binary Tree
  3. xwamp 目录结构设计
  4. HDU 1875 畅通工程再续 (最小生成树)
  5. [转]Getting (personal) tasks from the user profile.
  6. ShapeDrawable 资源
  7. JAVA中各种去除空格
  8. Vue 非父子组件通信
  9. 这是您一直期待的所有iOS 11功能的屏幕截图
  10. php连接memcahed出现Cannot assign requested address (99)的解决方法
  11. MYSQL数据库学习十八 数据库维护和性能提高
  12. 实战深度学习(上)OpenCV库
  13. Archery:开源漏洞评估和管理工具
  14. javascript中的高阶函数, 和 类定义Function, 和apply的使用
  15. 感言&2
  16. 开发winform程序,在拖拽控件大小时,VS会卡死
  17. webservice系统学习笔记10-使用jax-ws创建基于tomcat类型的容器的ws服务
  18. OAF_OAF控件系列1 - Region Type汇总(概念)
  19. New Concept English Two 19 49
  20. http和https区别

热门文章

  1. javascript 函数的4种调用方式与 this(上下文)的指向
  2. webstorm 2018.1 激活码 2018.4.8日更新
  3. 换个视角来看git命令与代码库发生网络交互报错事件
  4. 【基础】在css中绘制三角形及相关应用
  5. MySQL之SQL语句的优化
  6. HTML5新增的标签及使用
  7. countUp.js-让数字动起来
  8. python读取excel时,数字自动转化为float
  9. [LeetCode] Maximum Average Subarray I 子数组的最大平均值
  10. 深入java多线程一