This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes javascript to detect chrome url from iframe Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "javascript to detect chrome url from iframe" Watch "javascript to detect chrome url from iframe" New topic
Author

javascript to detect chrome url from iframe

yudi raj
Greenhorn

Joined: Nov 11, 2011
Posts: 12
I am having an application in an iframe and I am calling this from a different domain. For example, my browser url is a.com and my iframe url is b.com (different domain). I am loading this iframe (b.com) in a.com thus making their domains different.
I tried with the below function in js, this works in IE and Mozilla, however, with Google chrome, my js is not able to reach the browser url.
Would appreciate if anyone can give me some direction on this

Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
The same origin policy keeps a from talking to b.

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: javascript to detect chrome url from iframe
 
Similar Threads
Loading a jsp page in a popup loaded in another domain
Struts2: Accessing a request Parameter from Action
session migration
sharing of resources like html / jsp out of web application
how to specify domain in "url" , in getServletContext() . getContext("url")