homepage Welcome to WebmasterWorld Guest from 54.234.141.47
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Pubcon Platinum Sponsor 2014
Home / Forums Index / Code, Content, and Presentation / JavaScript and AJAX
Forum Library, Charter, Moderator: open

JavaScript and AJAX Forum

    
Unsafe JavaScript attempt to access frame with URL
vinothvijay



 
Msg#: 4600296 posted 5:40 am on Aug 2, 2013 (gmt 0)

Im my website i'm trying to load an external link (which is a flash type file) in a frame. It's throwing an error "Unsafe JavaScript attempt to access frame with URL" If i'm not wrong it's because of cross domain issue. Can some body help me out to resolve this.

Thanks in advance.

 

DrDoc

WebmasterWorld Senior Member drdoc us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 4600296 posted 3:09 pm on Aug 8, 2013 (gmt 0)

Welcome to WebmasterWorld!

How exactly are you loading the link? Using
location.href would be safe and would not cause an error.
Readie

WebmasterWorld Senior Member 5+ Year Member



 
Msg#: 4600296 posted 6:07 pm on Aug 8, 2013 (gmt 0)

If the target site is not on your domain, and that site is issuing this header:
X-Frame-Options: SAMEORIGIN

Then the browser will not load it within the iframe unless the security level of the browser is turned right down.

DrDoc

WebmasterWorld Senior Member drdoc us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 4600296 posted 10:19 am on Aug 12, 2013 (gmt 0)

vinothvijay, have you tested the headers sent back by the server?

Is your page and the current iframe on the same domain? Is your page and the target page on the same domain?

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