Why does setting document.domain require me to set it in all popups and iframes too?
Posted
by Chris
on Stack Overflow
See other posts from Stack Overflow
or by Chris
Published on 2010-05-04T12:15:48Z
Indexed on
2010/05/04
12:18 UTC
Read the original article
Hit count: 158
I'm using a long-polling iframe solution for a chat script. Unfortunately, this requires me to set document.domain='yourdomain.com' in the iframe and main document, because the iframe is a subdomain call.
The huge problem is...now all my other scripts that use popups and iframes are broken. They now require me to put document.domain in them too. It does fix it, but this is not an ideal solution at all. Is there another way around this problem?
© Stack Overflow or respective owner