How to call a page from another domain to my domain using ajax/javascript

删除回忆录丶 提交于 2019-12-13 02:34:13

问题


I would like to call and show a page from another domain to my domain using ajax/javascript. I would like to hide the original url of the page. (Example in the case of surveymoneky, I can load the survey page in my web site with out showing the surverymonkyes url.)

How can I do it ?

Thanks in advance..

Regards,

Sunil


回答1:


Due to the SOP (same origin policy) implemented in browsers, you can only retrieve information from another domain using Ajax if the other domain allows that by setting the Access-Control-Allow-Origin response header to the domain where the request originated.



来源:https://stackoverflow.com/questions/12261055/how-to-call-a-page-from-another-domain-to-my-domain-using-ajax-javascript

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!