[Home]Prevent getting framed

HomePage | RecentChanges | Preferences | Newbie Help

Category HTML FAQ

The short answer is that as an author, you cannot guarantee that your pages will not be displayed in frames. The code

<SCRIPT TYPE="text/javascript">
if (top.frames.length!=0)
// -->

has of course no effect when JavaScript is off. Moreover, a shrewd framer can beat it even when JavaScript is on. (Simply write an almost trivial server-side script that fetches your page, throws all JavaScript away from it, and returns the rest for display inside a frame.) Framing might be illegal, but there is no _technical_ way to ensure that your pages won't get framed. -- Jukka Korpela On Sun, 25 Mar 2001 13:01:36 GMT, in alt.html

A few links about the legal aspect

See also http://www.htmlhelp.com/faq/html/all.html#stop-framing

Comments --

HomePage | RecentChanges | Preferences | Newbie Help
This page is read-only | View other revisions
Last edited October 21, 2001 6:33 pm (diff)

This FAQ is happily hosted by Betadome Digital Media