Embedding a cs-cart website in an iFrame

一笑奈何 提交于 2019-12-11 20:35:17

问题


I am developing a cs-cart website for a customer, who wants to allow embedding of a "neutral" version of the site into other website. I have developed a second store, with neutral skin (white, no logos...) But when I try to embed it into an iframe on another site, nothing is shown. Other sites work. I undestrad this has to to with "same domain policy" What can be blocking my cs-cart website to ne shown in another site? What can be done to circumvent this?


回答1:


Your server is configured to tell browsers not to show the page in an iframe belonging to another site.

There is no way to work around that. Reconfigure the server so it doesn't output that header.




回答2:


found it:

i was in the prepare.php file in root path around line 86:

// Click-jacking protection
header("X-Frame-Options: sameorigin");

simply commented the option and then it worked :-)



来源:https://stackoverflow.com/questions/24555711/embedding-a-cs-cart-website-in-an-iframe

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