导航中的中英文切换

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>中英切换导航条</title> <style type="text/css"> *{padding:0; margin:0;} li{ list-style:none; } a{ text-decoration:none;} .nav{ width:100%; height:40px; background:#222; margin-top:100px; overflow:hidden;} .list{ width:1000px; height:40px; margin:0 auto;} .list li{ float:left;} .list li a{ display:block;}

.list b,.list i{ display:block; padding:0 30px; color:#aaa; line-height:40px; text-align:center;} .list b{ font-weight:100} .list i{ font-style:normal; background:#333; color:#fff;} </style>

<script type="text/javascript" src="http://libs.baidu.com/jquery/1.11.1/jquery.min.js"></script> <script type="text/javascript"> $(function(){ $(".list a").hover(function(){ $(this).stop().animate({"margin-top":-40},300) },function(){ $(this).stop().animate({"margin-top":0},300) }) }) </script>

</head>

<body>

</body> </html> 需要web前端课程工具和电子书,可以加群120342833

收藏 0分享浏览 1375
7年前
跟帖
暂无
说几句
广告位 点击查看投放指南

友情链接 大搜车前端团队博客
我的收藏