Frame-Breaker (Getting
out of someone else's frames)
Many
sites display a link to your web site within a
frame.
For
example, see http://www.BabyNamesIndia.com/toystore.html
and try clicking on any of amazon.com's links
from there, and you'll see the product page on
amazon.com being displayed within my frame (the
top half displays a page from my own site, and
the address bar shows a page on my site).
People
do it for various reasons -
To
let their visitor visit your site, yet
retain them within their own site
To
hide affiliate links
For
some complex navigational purposes (frames suck!)
One
more example is Hotmail. Any links that you open
from a hotmail email will display Hotmail.com's
ugly frame on top, and might hamper site functionality,
look or both, of the site being viewed.
Use
the script below, and your page will practically
"reload" itself if it finds itself bound
within another site's frame.
Again,
this has its disadvantages too - for example,
if the webmaster of another site sees that your
site breaks away from frames, he might change
his mind and not link to you from his site.
That
means, precious traffic lost from that site.
So,
try not to use it on your home page, because if
you have a useful site, many people will add an
unsolicited link to your site from their site
(which is a good thing!). So this script might
discourage those web masters. Use it wisely.
There
are two parts to this :
Paste the javascript code in Box 1 below, between
the <HEAD> and </HEAD> tags on your
page.