I have two web application settings:
david .example.com and john .example.com
David opens a new window to John:
window.open('john.example.com');
Now, John would like to set the input element back to David:
$("#input", window.opener.document).val("Hello David.");
My problem is that this does not work in most modern browsers due to the security of cross-domain scripting. I also tried to set document.domainfor different combinations of domains for both David and John without success.
The only time this works is if John is on example.com, and both options are document.domainset to example.com. However, it example.comis our main website and is not available as a solution.
How can I make the above example when the solution works in all modern security browsers?
Notes
- I manage
example.comall its subdomains. - David and John are separate web applications and cannot be hosted on the same subdomain.
source
share