说明: 可与IE整合、分离的导航条
效果: 运行后查看!
代码: 要完成此效果把如下代码加入到<body>区域中。
var ie5 = (document.getElementsByTagName != null);
function menuItemHighlight(el) { el.style.background = "highlight"; el.style.color = "highlighttext"; }
function menuItemNormal(el) { el.style.background = ""; el.style.color = ""; }
function raiseButton(el) { el.style.borderTop ="1 solid buttonhighlight"; el.style.borderLeft ="1 solid buttonhighlight"; el.style.borderBottom ="1 solid buttonshadow"; el.style.borderRight ="1 solid buttonshadow"; el.style.padding ="1"; el.style.paddingLeft = "7"; el.style.paddingRight = "7"; }
function normalButton(el) { el.style.border = "1 solid buttonface"; el.style.padding ="1"; el.style.paddingLeft = "7"; el.style.paddingRight = "7"; }
function pressedButton(el) { el.style.borderTop ="1 solid buttonshadow"; el.style.paddingTop = "2"; el.style.borderLeft ="1 solid buttonshadow"; el.style.paddingLeft = "8"; el.style.borderBottom ="1 solid buttonhighlight"; el.style.paddingBottom= "0"; el.style.borderRight = "1 solid buttonhighlight"; el.style.paddingRight = "6"; }
Copyright @ 2007-2012 敏韬网(敏而好学,文韬武略--MinTao.Net)(学习笔记) Inc All Rights Reserved. 闵涛 E_mail:admin@mintao.net(欢迎提供学习资源)
鄂公网安备 42011102001154号
站长:MinTao ICP备案号:鄂ICP备11006601号-18