Top Hat
27th February 2006, 15:42
A while ago I added some code to our pages to break out of frames, basically other sites were loading our site into a frame on their site.
<SCRIPT language="JavaScript"><!--
if (parent.frames.length > 0) {
parent.location.href = location.href;
}
// --></SCRIPT>
The code works well in that it breaks out of frames, but it breaks the back button as well (only if it was framed)
Should I dump this code?
Supplementary Q
<meta name="MSSmartTagsPreventParsing" content="TRUE">
Can I get rid of this now too?
<SCRIPT language="JavaScript"><!--
if (parent.frames.length > 0) {
parent.location.href = location.href;
}
// --></SCRIPT>
The code works well in that it breaks out of frames, but it breaks the back button as well (only if it was framed)
Should I dump this code?
Supplementary Q
<meta name="MSSmartTagsPreventParsing" content="TRUE">
Can I get rid of this now too?