Gwt doesn't run in IE and Chrome in local file system

不想你离开。 提交于 2020-01-03 21:01:18

问题


Gwt application is client side only and it doesn't use any server side functionality.Application will be run from user's local file system. Builded application runs only in FireFox and doesn't work in IE and Chrome. Can anyone says what is the reason?


回答1:


GWT by default loads your compiled code in an iframe, and different files on the filesystem have different "origins", so the iframes cannot communicate with each others (they hit the Same Origin Policy). This is a security measure.

You can use the xs or the new (2.1) xsiframe linkers instead, that load code through <script> tags. Just add this to your gwt.xml:

<add-linker name="xsiframe" />



回答2:


Did you compile the permutations for IS and Chrome?

GWT creates special JavaScript per Browser and language. Perhaps you only compiled for FF ?



来源:https://stackoverflow.com/questions/5357998/gwt-doesnt-run-in-ie-and-chrome-in-local-file-system

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