homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / JavaScript and AJAX
Forum Library, Charter, Moderator: open

JavaScript and AJAX Forum

Logging the websites that frame my pages

 7:23 pm on Dec 22, 2011 (gmt 0)

Do you guys know of technically viable method of logging all the websites that frame (iframe) my pages?




 9:12 pm on Dec 22, 2011 (gmt 0)

You could add a snippet of JavaScript to a page, similar to a frame buster scripts that detects it is being framed and then take action so that it is logged.

Recent thread about Google Images and frame busting [webmasterworld.com...]
and publication about framebusting [webmasterworld.com...] PDF 1,106KB)


 2:02 am on Dec 23, 2011 (gmt 0)

Many/Most browsers adhere to this code line like the below, which I add in my headers:

    <meta http-equiv="Window-Target" content="_top" />

For browsers that follow the Window-Target order, it should hopefully break out of the frame.
Easy to try out. Insert the header, and go to a site you have found to frame your stuff.

Best thing... No dependence on JavaScript.


 8:09 am on Dec 23, 2011 (gmt 0)

@ Dijkgraaf. i figured that too, but how do i actually send the info back to my server? Send an email? Can i call a php script from javascript? (Its more of a technical problem...)

@ DeeCee. I believe that in many cases that will result in a blank page being displayed in the iframe (i might be wrong).


 8:38 am on Dec 23, 2011 (gmt 0)

in fact, I could rephrase my question.

what methods are there for sending info from the JavaScript back to the server (sorry if it's a trivial question. i'm not very familiar with javascript)

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / JavaScript and AJAX
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved