CSS美化的立体按钮式的竖向排列的菜单
CSS美化的立体按钮式的竖向排列的菜单,每一个菜单项都是一个立体的按钮,以前有一个类似的,现在这款仅是改了一下颜色,优化了一下代码。
答案:<!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=gb2312" />
<title>纯CSS实现的按钮列表菜单-www.zzzyk.com</title>
<style type="text/css">
#gallery {width:150px; border:1px solid #000; padding:25px; background:#7ea089; margin:0 auto;}
* html #gallery {width:202px; w\idth:150px;}
#gallery dt {border:1px solid #fff; border-color:#000 #cde #cde #000; text-align:center; background:#698572; padding:5px 0; margin:7px 0; font-weight:bold; color:#fff;}
#gallery dd {padding:0; margin:3px 0; text-align:center; background:#b7cabd;}
#gallery div, #gallery span {border:1px solid #000;}
#gallery .hh {padding:1px 0;}
#gallery span {display:block;}
#gallery .aa {border-color:#b7cabd #698572 #698572 #b7cabd;}
#gallery .bb {border-color:#698572 #93b09c #93b09c #637e6c;}
#gallery .cc {border-color:#5a7362 #a2baaa #a2bbaa #5c7564;}
#gallery .dd {border-color:#5a7362 #a2baaa #a2bbaa #5c7564;}
#gallery .ee {border-color:#6f8d79; padding:0 2px 0 0;}
* html #gallery .ee {padding:0;}
#gallery a, #gallery a:visited {display:block;width:100%; border:1px solid #000; color:#840; text-decoration:none;}
#gallery .ff {border-color:#d1ddd5 #5f6962 #5f6962 #d0ddd4;}
#gallery .gg {border-color:#c9d7cd #7c8980 #7c8980 #c8d6dd;}
#gallery .hh {border-color:#c0d0c5 #9aaa9f #9aaa9f #bfd0c5;}
#gallery a:hover {background:#a2baaa; color:#000;}
#gallery a:hover .ff {display:block;border-color:#5f6962 #d0ddd4 #d1ddd5 #5f6962;}
#gallery a:hover .gg {display:block;border-color:#7c8980 #c8d6dd #c9d7cd #7c8980;}
#gallery a:hover .hh {display:block;border-color:#9aaa9f #bfd0c5 #c0d0c5 #9aaa9f; padding:2px 0 0 0;}
</style>
</head>
<body>
<dl id="gallery">
<dt>立体按钮菜单</dt>
<dd>
<div class="aa"><div class="bb"><div class="cc"><div class="dd"><div class="ee">
<a href="#" title=""><span class="ff"><span class="gg"><span class="hh">站长资源库</span></span></span></a>
</div></div></div></div></div>
</dd>
<dd>
<div class="aa"><div class="bb"><div class="cc"><div class="dd"><div class="ee">
<a href="#" title=""><span class="ff"><span class="gg"><span class="hh">资源导航</span></span></span></a>
</div></div></div></div></div>
</dd>
<dd>
<div class="aa"><div class="bb"><div class="cc"><div class="dd"><div class="ee">
<a href="#" title=""><span class="ff"><span class="gg"><span class="hh">网页特效</span></span></span></a>
</div></div></div></div></div>
</dd>
<dd>
<div class="aa"><div class="bb"><div class="cc"><div class="dd"><div class="ee">
<a href="#" title=""><span class="ff"><span class="gg"><span class="hh">分类索引</span></span></span></a>
</div></div></div></div></div>
</dd>
<dd>
<div class="aa"><div class="bb"><div class="cc"><div class="dd"><div class="ee">
<a href="#" title=""><span class="ff"><span class="gg"><span class="hh">留言本</span></span></span></a>
</div></div></div></div></div>
</dd>
<dd>
<div class="aa"><div class="bb"><div class="cc"><div class="dd"><div class="ee">
<a href="#" title=""><span class="ff"><span class="gg"><span class="hh">下载排行</span></span></span></a>
</div></div></div></div></div>
</dd>
</dl>
</body>
</html>
上一个:竖向蓝色漂亮CSS菜单,移动鼠标变背景
下一个:很不错的阴影菜单,仿XP经典风格