当前位置:编程学习 > JS >>

精致纯CSS导航栏

极精致的纯CSS实现的菜单,兼容性非常好,条例WEB标准,能用性好,用到有修饰图片,请根据代码地址自己下载。
答案:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml2/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>精致纯CSS导航栏</title>
<style type="text/css">
.pro10 {padding:0 0 0 32px; margin:0; list-style:none; height:30px; position:relative;}
.pro10 li {float:left; background:url(/jscss/demoimg/200905/pro_ten_1.gif);}
.pro10 li a {display:block; float:left; height:30px; line-height:29px; background:url(/jscss/demoimg/200905/pro_ten_0.gif) no-repeat; color:#ddd; text-decoration:none; font-size:11px; font-family:arial, verdana, sans-serif; font-weight:bold; text-align:center; padding:0 0 0 15px; cursor:pointer;}
.pro10 li a b {float:left; display:block; padding:0 15px 0 0; background:url(/jscss/demoimg/200905/pro_nine_0.gif) right top;}
.pro10 li.current a {color:#fff; background:url(/jscss/demoimg/200905/pro_ten_2.gif);}
.pro10 li.current a b {background:url(/jscss/demoimg/200905/pro_ten_2.gif) right top;}
.pro10 li a:hover {color:#fff; background:url(/jscss/demoimg/200905/pro_ten_1.gif);}
.pro10 li a:hover b {background:url(/jscss/demoimg/200905/pro_ten_1.gif) right top;}
.pro10 li.current a:hover {color:#fff; background:url(/jscss/demoimg/200905/pro_ten_2.gif); cursor:default;}
.pro10 li.current a:hover b {background:url(/jscss/demoimg/200905/pro_ten_2.gif) right top;}
</style>
</head>

<body>
<ul class="pro10">
<li><a href="/"><b>网站主站</b></a></li>
<li><a href="#"><b>最新更新</b></a></li>
<li><a href="#"><b>Products</b></a></li>
<li><a href="/jscss/"><b>网页特效</b></a></li>
<li class="current"><a href="/jscss/"><b>Contact us</b></a></li>
<li><a href="/jscss/"><b>Search</b></a></li>
</ul>
</body>
</html>

上一个:纵向无序的CSS列表菜单
下一个:CSS竖向滑动展开的折叠菜单

CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,