jquery02-09图片网站导航效果
来源:互联网 发布:淘宝客服一般几点下班 编辑:程序博客网 时间:2024/06/05 06:38
<!DOCTYPE html><html><head lang="en"> <meta charset="UTF-8"> <title></title> <style> *{ margin: 0; padding: 0; } img{ vertical-align: top; } .wrap{ width: 775px; height: 285px; border: 1px solid #ccc; margin: 100px auto; } .wrap ul{ list-style:none; padding: 5px 5px; } .wrap ul li{ float: left; padding: 3px 5px; position: relative; height: 135px; overflow: hidden; } .wrap ul li img{ width: 180px; height: 130px; display: block; } .wrap div{ width: 178px; height: 25px; background:#000; position: absolute; bottom: -25px; /*opacity: 0.5;*/ /*filter:alpha(opacity=40);*/ } .wrap p{ width: 178px; height: 25px; /*background:url("images/bg.png") no-repeat 5px 0;*/ line-height: 25px; text-align: center; font-size: 14px; color:white; position: absolute; bottom: -25px; } </style> <script src="jquery-1.11.1.min.js"></script> <script> $(function () { $(".wrap li") .append("<div></div><p>百度一下,你就知道</p>") .children("div") .fadeTo(500,0.5) .next("p") .each(function (index, ele) { $(this).css("background-position","5px -"+(index * 25) +"px"); }) .parent() .mouseenter(function () { $(this).children("div,p").stop().animate({ "bottom":"0px" },400); }).mouseleave(function () { $(this).children("div,p").stop().animate({ "bottom":"-25px" },400); }) ;// $(".wrap li").mouseenter(function () {// $(this).children("div,p").stop().animate({// "bottom":"0px"// },400);// }).mouseleave(function () {// $(this).children("div,p").stop().animate({// "bottom":"-25px"// },400);// }); }); </script></head><body><div class="wrap"> <ul> <li><a href="#"><img src="chrome://thumb/http://www.baidu.com/" alt=""/></a></li> <li><a href="#"><img src="chrome://thumb/http://www.sohu.com/" alt=""/></a></li> <li><a href="#"><img src="chrome://thumb/http://weibo.com/?c=spr_qdhz_bd_360aqllqdh_weibo_001" alt=""/></a></li> <li><a href="#"><img src="chrome://thumb/http://u.ctrip.com/union/CtripRedirect.aspx?TypeID=2&Allianceid=323047&sid=803568&OUID=&jumpUrl=http://www.ctrip.com" alt=""/></a></li> <li><a href="#"><img src="chrome://thumb/http://www.360kan.com/?src=se_newtab_zcfw" alt=""/></a></li> <li><a href="#"><img src="chrome://thumb/http://www.taobao.com/" alt=""/></a></li> <li><a href="#"><img src="chrome://thumb/http://www.163.com/" alt=""/></a></li> <li><a href="#"><img src="chrome://thumb/http://www.sina.com.cn/" alt=""/></a></li> </ul></div></body></html>
0 0
- jquery02-09图片网站导航效果
- jquery02
- jquery02
- 网站图片查看效果
- 仿淘宝网站的TabPage导航效果
- 仿淘宝网站的导航标签效果
- jquery实现网站导航动画滑动效果
- 清爽简洁的图片交替导航效果
- bootstrap图片轮播+导航栏效果
- 清爽简洁的图片交替导航效果
- Jquery实现360图片导航效果
- JS图片类之苹果导航效果
- Jquery02选择器
- jquery02总结
- Day06-jQuery02
- 纯css实现网站导航条下拉效果
- 网站超链接和图片提示效果(jquery)
- 图片滚动效果插件参考网站
- Python实战小程序——matplotlib模块画图
- 工作与生活要分离,走出舒适区
- 日常笔记:Linux(Ubuntu) and shell
- 矩形覆盖(java)
- 单独编译一个ipk
- jquery02-09图片网站导航效果
- 原型链总结
- 《OpenCV3编程入门》学习笔记之官方例程学习
- 杭电1003
- spark rdd详解二(transformation与action操作)
- 屏蔽网易博客碍眼的注册窗口
- pip-pop源码阅读笔记
- Android Studio遇到的问题
- nhibernate的关系