背景透明代码兼容各大浏览器css代码
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>背景透明代码兼容各大浏览器css代码</title>
<style>
body{ width:1000px; margin:100px auto; padding:0;}
.div{ background:red; width:300px; height:200px;}
.div2{background-color:#000;width:200px; height:100px; color:#fff;
filter:alpha(opacity=50);-moz-opacity:0.5;-khtml-opacity:0.5;opacity:0.5;opacity:0.5;}
</style>
</head>
<body>
<div class="div">
<div class="div2">看,背景透明吧!</div>
</div>
</body>
</html>
除注明外的文章,均为来源:老汤博客,转载请保留本文地址!
原文地址:https://tangjiusheng.cn/divcss/39.html
原文地址:https://tangjiusheng.cn/divcss/39.html