1NetMedia_Blog
Home
Html
ASP/.NET
PHP
APP
JS
Ajax
Flash
SEO
Document
Design
Data
Private
<< JS去除标签中的修饰代码,只留纯...
类别:
Html
图片滑动效果 >>
仿狗狗超炫菜单效果
[ 日期: 2007-06-16 10:35:46 AM | 作者:
admin
| 来源:
三原色代码示例<
| 人气:33906 |
|
] 字号: 【
大
中
小
】
急速栏目链接:
标签:
仿狗狗超炫菜单效果
运行代码看效果,酷毙了。
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html;charset=gb2312"> <title>仿狗狗超炫菜单效果</title> <style type="text/css"> <!-- body {text-align:center} table {border:1px solid #eeeeee;padding:3px 0;border-bottom-width:5px} .icon td {width:50px;height:37px;background-image:url(attachments/month_200706/16_103334_52t8icolist.gif)} .capt td {font:normal 11px verdana;padding:2px 0} .a {background-position-y:0px} .b {background-position-y:-37px} .c {background-position-y:-74px} .d {background-position-y:-111px} .e {background-position-y:-148px} .f {background-position-y:-185px} .g {background-position-y:-222px} .f1 {background-position-x:0px} .f2 {background-position-x:-51px} .f3 {background-position-x:-101px} .f4 {background-position-x:-153px} .f5 {background-position-x:-205px} .f6 {background-position-x:-257px} .f7 {background-position-x:-309px} --> </style> <script language="javascript"> window.onload=function(){ var t=document.getElementsByTagName('table')[0]; var cs=t.rows[1].cells,ct=t.rows[0].cells; for(var i=0;i<cs.length;i++) cssAni(cs[i],ct[i],7); } function cssAni(osrc,otarget,num,duration){ var t=null,c=1,d=0,n=0,i=Math.floor((duration||300)/num); var s=otarget.className.replace(/.$/,''),r=/over/; osrc.onmouseover=osrc.onmouseout=function(e){ n=r.test((e||event).type)?1:-1; if(!t) t=setInterval(function(){ if((c==1||c==num)&&((d==n||c+n<1)||!(d=n))) return clearInterval(t),t=null; otarget.className=s+(c+=d); },i); }; } </script> </head> <body> <table> <tr class='icon'> <td class='a f1'></td> <td class='b f1'></td> <td class='c f1'></td> <td class='d f1'></td> <td class='e f1'></td> <td class='f f1'></td> <td class='g f1'></td> </tr> <tr class='capt'> <td><a href='#;'>A</a></td> <td><a href='#;'>B</a></td> <td><a href='#;'>C</a></td> <td><a href='#;'>D</a></td> <td><a href='#;'>E</a></td> <td><a href='#;'>F</a></td> <td><a href='#;'>G</a></td> </tr> </table> </body> </html>
复制代码
另存代码
提示:您可以先修改部分代码再运行
所用到的图片,做成一张。其实就是控制背景图的位置实现的,鼠标放上去就不断的变换背景图位置。
收藏本文
复制地址
打印本文
关闭页面
没有相关评论
发表评论
请先注册,才能发表评论!
- 注册 -
用户登陆
用户:
密码:
验证:
日志搜索
标签
主题
评论
本站
网络
相关信息
网络收藏夹
(19)
资源共享
(17)
留言本
(17)
站点日历
<<
<
2021
-
04
>
>>
日
一
二
三
四
五
六
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
最近日志
- CSS垂直布局自适应高度解...
- css三栏布局大全(7种布局...
- asp获取远程网站源码并显...
- ES6中三个点扩展运算符(s...
- 获取鼠标点击元素
- Js中Array对象的reduce方...
- Chrome Ajax 跨域设置
- 一些有用的JS正则表达式
- h5在光标位置插入内容,点...
- js常见的内存泄漏及解决方...
最近评论
- 我的是在判断之后取回的数...
- 谢谢啦。。。。帮你顶顶
- 回去就去试试 不错
- http://home.donews.com/...
- 我帮你补充一些
- 兄弟,最后一个TABLE...
- 请博主注明: 全部来自:...
- 吊啊~~
- 很好
- 表面看只是个 玩具头而已...
站点统计
日志: 1491 篇
评论: 54 篇
引用: 0 个
会员: 148 人
访问:33454182 次
建立: 2005-03-30
友情链接
本站logo,欢迎交换链接!
设为首页
-
加入收藏
-
广告服务
-
友情链接
-
站长信箱
-
在线交流
-
繁體中文
版权所有 © 2006-2007
1netmedia.cn
, All Rights Reserved. 推荐使用1024*768分辨率浏览本站
本站博客技术支持 2S-blog: http://www.2s-space.com/
湘ICP备08104616号 页面载入时间:0.078125 秒