Here's what's going on:
I have an application A
hosted on a.mycompany.com
and an application B
hosted on b.mycompany.com
Application A
contains an iframe containing a page contained in the application B
.
<!-- In A's index.html: -->
<iframe src="http://b.mycompany.com/something.html" >
I need to have either the parent talk to the iframe or the iframe talk to the parent.
It works fine when it's on the server, but when I'm developping locally I have two different servers running on different ports so I have to access them via:
http://a.mycompanydev.com:1234
http://b.mycompanydev.com:5678
And this leads to a security error since you can't communicate using JS with an iframe from a different domain/subdomain or using a different port.
What can I do??
Related serverfault question: http://serverfault.com/questions/148171/how-to-map-localhost8080-to-simply-localhost