简体   繁体   中英

load external div into iframe using ajax

I'm running into a brick wall and can't get this to function properly.

How can I load the #content div from http://some-cross-domain-site.com/index.php into an IFrame on my site?

Short answer: you can't unless you load the page via a proxy page on your own domain.

To stop malicious users from injecting JavaScript that loads viruses and spyware from an unknown domain, modern browsers have built in security that disables cross site scripting (XSS) with a few exceptions.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM