Home  >  Article  >  Web Front-end  >  Please show me what's wrong with this drop-down menu_html/css_WEB-ITnose

Please show me what's wrong with this drop-down menu_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 12:12:47953browse

<!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 runat="server">    <title>123</title>    <link href="style.css"  rel="stylesheet" type="text/css" /><!-- saved from url=(0013)about:internet --></head><div id="bar">	<div id="nav">	<ul>		<li><a href="#" target="_blank">网站主页</a>				</li>		<li><a href="#" target="_blank">文档管理</a>			<ul style="z-index:88;">				<li>类别管理</li>				<li>信息管理</li>				<li>文档下载</li>				<li>文档上传</li>			</ul>		</li>		<li><a href="#" target="_blank">用户管理</a>			<ul style="z-index:99;">				<li>用户管理</li>				<li>用户管理</li>				<li>用户管理</li>				<li>用户管理</li>				<li>用户管理</li>			</ul>		</li>		<li><a href="#" target="_blank">留言建议</a>		</li>	</ul>	</div></div>   </body></html>


a{	text-decoration:none;}#bar{	width:100%;	height:40px;	z-index:999;	padding-top:5px;	background:url(bar_bg.gif) repeat-x; 	}#nav{	width:960px;	height:30px;	margin:0 auto;	}#nav ul {	padding:0; 	margin:0;         list-style-type: none;	}#nav ul li{	list-style:none;	float:left;	position:relative;	width:100px;	}#nav ul li a{	display:block;	text-align:center;	line-height:28px;	padding-left:9px;	padding-right:9px;	color:#bdbde2;	height:30px;         }#nav ul li:hover a{	background-color:#000066;	color:#00FF99;	}#nav ul li ul {	display: none;	}#nav ul li:hover ul {	display:block; 	top:30px; 	position:absolute; 	width:80px;         color:#00FF99;	text-align:center;         }#nav ul li:hover ul li {	background-color:#333333;	display:block;	color:#bdbde2;	height:28px;	padding-top:4px;	width:100px;	}#nav ul li:hover ul li a {	display:block;	color:#bdbde2;	background:#1C5579; 	}#nav ul li:hover ul li a:hover {	background-color:#000066;	color:#00FF99;	}


This is the source code, experts please take a look at it


Reply to the discussion (solution)

Do you feel it? How do you feel?... What do you feel? What do you think?

Did the original poster see the effect in IE6?

Want to ask why li:hover does not respond?

IE6 supports pseudo-classes other than a, which can be done with js, onmouseover and onmouseout

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn