<body>
<h1>test2</h1>
</body>
</html>
test3.html页面代码:
<html>
<head>
<title></title>
</head>
<body>
<h1>test3</h1>
</body>
</html>
这个小例子主要是iframe标签的allowTransparency属性应用,在该属性设置为true并且iframe所加载的子页面的<body>标签背景颜色设置为transparent(透明)时,iframe将透明化。
allowTransparency设置或获取对象是否可为透明。
bgColor 设置或获取对象的背景颜色。









