2012-01-12 57 views
0

在Internet Explorer 7中,顶级水平菜单显示页面上div标签下的子类别。菜单的项目是相对或绝对定位的,z-index高于div标签'。我如何让下拉菜单出现在页面中的其他所有内容之前?IE7与下拉菜单切割与其他元素

请在IE7浏览器一看www.luxos.com,请帮我来说,似乎没有办法从这个

这里走出去的CSS代码WHIS我使用IE7 CSS

#head-nav { height: 35px; right:149px;} 

#head-nav li{ position: relative; } 


#head-nav li .subnav{z-index:99999;} 
.subnav-viewport {z-index:99999;} 

这里是它是所有其他浏览器

ul#head-nav {font-family:Arial, Helvetica, sans-serif;font-size: 13px;position: absolute;top: 104px;letter-spacing: .1em;} 
ul#head-nav li {float:left;margin:0px 1px 0px 0px;padding: 0;position:relative;} 

/*ul#head-nav li a {color:#000;text-decoration:none;padding:0 0 3px 0;font-weight:300;} 
ul#head-nav li a:hover {border-bottom:5px solid #ccc}*/ 

/*---------------------New Menu navigation system 02/08/2010--------------*/ 
/*.menubutton{background:url("../images/menu-button-slice.jpg") no-repeat scroll right 0 transparent;padding:0px 4px 0px 0px;display:inline-block;} 
.menubutton a{background:url("../images/menu-button.jpg") no-repeat scroll 0 0 transparent;color:#FFFFFF;padding:0px 9px 0px 15px;display:inline-block;height:25px;line-height:23px;}*/ 

/*---------------------Menu Buttons changed 23/02/2011----------------------*/ 
.menubutton{background:#58595b;padding:0px;display:inline-block;width:150px;text-align:center;} 
.menu-down-button{background:url("/interface/images/menu-down.jpg") no-repeat scroll 124px 8px #58595b;padding:0px;display:inline-block;width:150px;text-align:center;} 
.menubutton a{color:#FFFFFF;display:inline-block;height:25px;line-height:23px;} 

ul#head-nav li .subnav{width:150px;position:absolute;background:#ffffff;padding:4px 0px;margin:0px;display:none;z-index:99;background: url("/interface/images/menu-dropdown-bg.gif") repeat-y 0 0;border-bottom:1px solid #cfcfcf;} 
ul#head-nav li .subnav li {float:none;padding:0px;margin:0px;display:block;height:20px;} 
ul#head-nav li .subnav li.menu-divider {border-top:1px dashed #444444;width:120px; display:block;height:2px;margin:4px 7px;} 
ul#head-nav li .subnav a, .menu-title{color:#808080;font-family:Helvetica,Arial,"Liberation Sans","Bitstream Vera Sans",sans-serif;font-size:12px;display:block;padding:0px 8px;;margin:1px 0px 1px 0px;letter-spacing:0;} 
ul#head-nav li .subnav a:hover{background:#444444;color:#ffffff;} 
.subnav-viewport {display:none;position:absolute;height:457px;width:136px;overflow:hidden;z-index:999;left:0;top:19px;background: url("/interface/images/subnav-viewport-arrow-bg.gif") no-repeat 0 0;padding-top:8px;} 
.subnav-viewport li.down{} 
.subnav-viewport li.up{} 

.menu-title{font-weight:bold;padding:0px 8px !important;} 
.menu-bold{font-weight:bold;} 

ul#head-nav li .subnav li.menu-underline a{text-decoration:underline;} 

回答

1

你的页面从an IE7 bug痛苦的代码。

在这种特定的情况下,可以通过以下步骤解决这个问题:

  • #head-nav,加z-index: 1
  • #header上,删除position: relative
  • 不幸的是,您的标题现在稍微打破了。要修复它,请在a#head-logobottom: 63px更改为top: 28px
+0

非常感谢老板,JOB DONE,谢谢 – user1145298 2012-01-12 16:46:53