"IE6 Below"
The IFRAME border is set by CSS in the normal under the FF under IE but there is still a border, through the IFRAME tag inside the Set property frameborder= "No" border= "0" can remove the nasty iframe border.
<iframe src= "url" id= "iframe" width= "0" height= "0" frameborder= "no" border= "0" ></iframe>
"Ie7ie8"
Encountered a depressed problem, ie8,ie7 iframe borders can not be removed, tried to use scripts and styles to add Frameborder,border properties can not be removed.
The setting is valid before the IFRAME append to the page, and there is no way to modify it after append. As follows:
The
code is as follows:
<iframe id= "B" ></iframe>
<!--<iframe id= "B" frameborder= "0" ></iframe>-->
<script type= "Text/javascript" >
var IFR = document.createelement (' iframe ');
ifr.setattribute (' frameborder ', 0); With me no border
Document.body.appendChild (IFR);
//ifr.setattribute (' frameborder ', 0); Use me to have border
Ifr.style.cssText = ' border:0 none; ';
</script>
<script type= "Text/javascript" >
var div = document.createelement (' div ');
Document.body.appendChild (DIV);
div.innerhtml = ' <iframe id= ' a ' ></iframe> '; Use me to have border
//div.innerhtml = ' <iframe id= ' a ' frameborder= ' 0 ' ></iframe> '; With me no border
var IFR = document.getElementById (' a ');
ifr.setattribute (' frameborder ', 0);
Ifr.style.cssText = ' border:0 none; ';
</script>
<script type= "Text/javascript" >
var IFR = document.getElementById (' B ');
ifr.setattribute (' frameborder ', 0);
Ifr.style.cssText = ' border:0 none; ';
</script>