File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes HTML, CSS and JavaScript and the fly likes child window parent window different domain Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "child window parent window different domain" Watch "child window parent window different domain" New topic

child window parent window different domain

Amit Da

Joined: Mar 07, 2003
Posts: 16
I have my application running at say
On a button click it opens a window doing and passes URL of our own web application, which is hosted at
Now when user performs some action in the 2nd app and clicks a button we want to call a javascript function from first app and perform some action such as refresh of page in parent window (thats in app1). This all works fine as long as the page l opens window with a page in same application app1. But the cross domain stuff doesn't work due to browser security. How can I make this happen??? Has anyone come across such a case? What I can't, and don't want to do is - app2's button click updating a database table row and the parent window-keeps polling the table row to see if it got updated, to know if the child window is closed...Parent window needs to know if child window was closed due to OK click or Cancel do I achieve this? any clues...?
Eric Pascarello

Joined: Nov 08, 2001
Posts: 15385
JavaScript has the same domain policy, you can not talk to the other domain.

I agree. Here's the link:
subject: child window parent window different domain
It's not a secret anymore!