读书人

CSS 属性继承,该如何解决

发布时间: 2012-03-31 13:13:26 作者: rapoo

CSS 属性继承
在IE8,Firefox, Safari中DIV在没有设置背景颜色,怎样让DIV继承Span的背景颜色,需要什么CSS设置

<html>
<head>
<meta http-equiv= "Content-Type " content= "text/html; charset=GB2312 ">
<title> Background </title>
<style type= "text/css ">
.para{
font-family:Arial;
font-size:10pt;
}
</style>
</head>

<body>
<span style= "background-color:red; ">
<div class= "para ">
The duties and responsibilities of Check Airman, Check Dispatcher, Check Flight Attendant, and Ground, Aircraft and Simulator
Instructors are detailed in the Crewmember and Dispatcher Training Manual.
</div>
</span>
</body>
</html>

[解决办法]

探讨
是的 原本不能继承的 现在就是需要span下面的div也有背景颜色

读书人网 >CSS

热点推荐