<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
<style>
div.wrap{
width:300px;
height: 200px;
margin: 50px auto;
padding-top:100px;
line-height: 60px;
text-align: center;
background: rgba(0,0,0,0.2);
color: #000;
font-family:"MicroSoft Yahei";
font-size: 30px;
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType=1,startColorstr=#80000000,endColorstr=#80000000)"; /*Filter for IE8 */
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=1,startColorstr=#80000000, endColorstr=#80000000); /*Filter for older IEs */
}
</style>
</head>
<body>
<div class="wrap">关于Css3背景透明属性的测试</div>
</body>
</html>
时间: 2024-10-05 22:08:28