我的这段CSS代码在IE6里没反应,但是在IE7、IE8、火狐里都好使,请高手给我看看,急!!!
<!DOCTYPEhtmlPUBLIC"-//W3C//DTDXHTML1.0Transitional//EN""http://www.w3.org/TR/xhtml1/...
<!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" lang="gb2312">
<head>
<head>
<title>首页</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"/>
<link href="resource/css/public.css" rel="stylesheet" type="text/css" />
<link href="resource/css/123.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div class="back">
<div class="logolft">
您当前所处的城市是 <span class="f50 b">北京</span></div>
<div id="cut_over" class="cut_over"><a href="">[切换出发城市]</a>
<div id="citymenu"><a href="">北京</a><a href="">上海</a><a href="">广州</a><a href="" target="_self">深圳</a><a href="" target="_self">天津</a><a href="" target="_self">杭州</a><br/><a href="" target="_self">西安</a><a href="" target="_self">重庆</a><a href="" target="_self">大连</a><a href="" target="_self">宁波</a><a href="" target="_self">南京</a><a href="" target="_self">青岛</a><br/><a href="" target="_self">武汉</a><a href="" target="_self">厦门</a><a href="" target="_self">无锡</a><a href="" target="_self">郑州</a><a href="" target="_self">成都</a><a href="" target="_self">昆明</a><br/><a href="" class="more" target="_self">更多城市</a></div>
</div>
</div>
</body>
</html>
下面是CSS
.back{position:relative;z-index:1; width:950px}
.logolft{position:absolute; left:20px; top:10px; text-align:left}
.logolft{ top:10px;}/*FF环境 */
*html .logolft{ top:20px;} /*IE6环境 */
*+html .logolft{ top:20px;} /*IE7环境 */
.cut_over{ position:absolute; left:20px; top:25px; display:block; width:106px; cursor:pointer; font-size:12px; background:url(../images/arrowD.jpg) no-repeat 96px 4px;}
.cut_over a:hover{border: none;}
*html .cut_over{ top:35px;}
*+html .cut_over{ top:35px;}
/***** 城市切换 *****/
#cut_over #citymenu{display:none;}
#cut_over.hover #citymenu,#cut_over:hover #citymenu{display:block;}
#citymenu{position:absolute; left:0; top:18px;border:1px solid #EFEFEF; background:#FFFFFF; width:216px; padding:5px;}
#citymenu a{padding:0 6px;line-height:20px;}
#citymenu .more{ float:right; padding-right:24px; background:url(/images/list.gif?080819) no-repeat 56px -45px;cursor:pointer;} 展开
<html xmlns="http://www.w3.org/1999/xhtml" lang="gb2312">
<head>
<head>
<title>首页</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"/>
<link href="resource/css/public.css" rel="stylesheet" type="text/css" />
<link href="resource/css/123.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div class="back">
<div class="logolft">
您当前所处的城市是 <span class="f50 b">北京</span></div>
<div id="cut_over" class="cut_over"><a href="">[切换出发城市]</a>
<div id="citymenu"><a href="">北京</a><a href="">上海</a><a href="">广州</a><a href="" target="_self">深圳</a><a href="" target="_self">天津</a><a href="" target="_self">杭州</a><br/><a href="" target="_self">西安</a><a href="" target="_self">重庆</a><a href="" target="_self">大连</a><a href="" target="_self">宁波</a><a href="" target="_self">南京</a><a href="" target="_self">青岛</a><br/><a href="" target="_self">武汉</a><a href="" target="_self">厦门</a><a href="" target="_self">无锡</a><a href="" target="_self">郑州</a><a href="" target="_self">成都</a><a href="" target="_self">昆明</a><br/><a href="" class="more" target="_self">更多城市</a></div>
</div>
</div>
</body>
</html>
下面是CSS
.back{position:relative;z-index:1; width:950px}
.logolft{position:absolute; left:20px; top:10px; text-align:left}
.logolft{ top:10px;}/*FF环境 */
*html .logolft{ top:20px;} /*IE6环境 */
*+html .logolft{ top:20px;} /*IE7环境 */
.cut_over{ position:absolute; left:20px; top:25px; display:block; width:106px; cursor:pointer; font-size:12px; background:url(../images/arrowD.jpg) no-repeat 96px 4px;}
.cut_over a:hover{border: none;}
*html .cut_over{ top:35px;}
*+html .cut_over{ top:35px;}
/***** 城市切换 *****/
#cut_over #citymenu{display:none;}
#cut_over.hover #citymenu,#cut_over:hover #citymenu{display:block;}
#citymenu{position:absolute; left:0; top:18px;border:1px solid #EFEFEF; background:#FFFFFF; width:216px; padding:5px;}
#citymenu a{padding:0 6px;line-height:20px;}
#citymenu .more{ float:right; padding-right:24px; background:url(/images/list.gif?080819) no-repeat 56px -45px;cursor:pointer;} 展开
3个回答
展开全部
#cut_over.hover #citymenu,#cut_over:hover #citymenu{display:block;}
这种HOVER现像在IE6下是不支持的。建议用hack解决
这种HOVER现像在IE6下是不支持的。建议用hack解决
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
在属性后面添加“黑盒”属性:!important
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询