我无法删除IFrame中的背景颜色,所以请帮助我。我的宝贵时间耗尽了: - (
答案 0 :(得分:3)
虽然这与PHP无关,但我认为您正在寻求如下答案。如果您有权使用iFrame编辑指向的页面内容,则可以使用简单的CSS属性删除背景。尝试将其添加到文档的开头:
<style type="text/css">
body {
background-color:transparent;
}
</style>
如果在iFrame之外的任何时间访问此页面,只需设置一个PHP(如果设置某个变量,if语句应该有效),如果iFrame页面正在访问它,则启用/禁用这段代码。
在iframe中添加此参数
allowtransparency="true"
所以你的iframe应该看起来像这样(从你的页面复制)
<iframe src="http://www.orangerich.info/crm/freetrialform/form.php" height="360" width="320" frameborder="0" scrolling="No" allowtransparency="true"></iframe>
祝你好运!