html css js树形菜单,JS+CSS实现TreeMenu二级树形菜单完整实例

本文实例讲述了JS+CSS实现TreeMenu二级树形菜单。分享给大家供大家参考。具体如下:

这是一款二级树形菜单示例:CSS TreeMenu ,非常漂亮的树形菜单,用在网站右侧比较合适。

运行效果截图如下:

b18c2606e62703ec998e7d6e0cfcb664.png

在线演示地址如下:

具体代码如下:

/p>

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

二级树形菜单示例:CSS TreeMenu

a,a:visited {color:#333;text-decoration:none;}

a:hover {color:#f60;}

body,td {font:13px "Geneva","宋体", "Arial", "Helvetica",sans-serif;}

ul,li {margin:0;padding:0;list-style:none;}

h1,h2,h3,h4,h5,h6 {margin:0;padding:0;}

h1 {padding:5px;color:#900;font:16px bold "Geneva","宋体", "Arial", "Helvetica",sans-serif;}

h1 small {font-size:11px;font-weight:normal;color:#660;}

.TreeWrap {width:200px;}

.MenuBox .titBox a,

.MenuBox .titBox a:visited,

.MenuBox2 .titBox a,

.MenuBox2 .titBox a:visited {margin-left:10px;padding-left:40px;color:#003;font-size:12px;display:block;}

.MenuBox .titBox h3 a {background:url(images/ico_folder_open.gif) no-repeat 0 40%;}

.MenuBox .titBox h3.Fst a {background:url(images/ico_folder_open_fst.gif) no-repeat 0 40%;}

.MenuBox .titBox h3.Lst a {background:url(images/ico_folder_open_lst.gif) no-repeat 0 40%;}

.MenuBox2 .titBox h3 a {background:url(images/ico_folder.gif) no-repeat 0 40%;}

.MenuBox2 .titBox h3.Fst a {background:url(images/ico_folder_fst.gif) no-repeat 0 40%;}

.MenuBox2 .titBox h3.Lst a {line-height:250%;background:url(images/icon_exit.gif) no-repeat 0 0;}

.MenuBox2 .txtBox {display:none;}

.MenuBox .txtBox ul li {padding-left:65px;line-height:150%;}

.MenuBox .txtBox .num {color:#e00;}

.MenuBox .txtBox ul {background:url(images/line_y.gif) repeat-y 16px 0;}

.MenuBox .txtBox ul li {background:url(images/t.gif) no-repeat 28px 50%;}

.MenuBox .txtBox ul li.Lst {background:url(images/t_lst.gif) no-repeat 28px 50%;}

CSS TreeMenu By 枫岩@IECN.Net

希望本文所述对大家的JavaScript程序设计有所帮助。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值