我有一个应用程序使用GWT 2.0.4并且在IE8浏览器上运行良好。 在IE11中打开时,它会显示空白页面,并显示以下错误消息。
com.google.gwt.core.client.JavaScriptException : (TypeError) : Object doesn’t support property or method ‘attachEvent’抛出异常是因为“attachEvent”是旧版Internet Explorer中使用的弃用函数。 IE11使用“addEventListener”方法而不是“attachEvent”。
user.agent值被设置为“ie6”,所以我将它改为“gecko1_8”。 在更改用户代理之后,它将打开应用程序,但表中的数据(GWT-ext GridPanel)正在彼此重叠,滚动条丢失并且菜单栏的对齐方式发生更改。
启用兼容模式后它工作正常。 什么是在IE11中运行我的应用程序的正确解决方法? 我是否需要升级GWT,如果是,那么哪个版本支持IE11? 我不必使用“X-UA兼容= IE8”元标记....请帮助
I have an application that is using GWT 2.0.4 and running fine on IE8 browser. When opened in IE11, it is giving blank page with error message given below.
com.google.gwt.core.client.JavaScriptException : (TypeError) : Object doesn’t support property or method ‘attachEvent’The exception was thrown because “attachEvent” is a deprecated function used in older versions of Internet Explorer. IE11 uses “addEventListener” method instead of “attachEvent”.
The user.agent value was set to "ie6" so i changed it to "gecko1_8". After changing user agent it opens the application but the data in table(GWT-ext GridPanel) is getting overlapped over one another, scrollbars are missing and the alignment of menu bar is changed.
It is working fine after enabling the compatibility mode. What is the proper workaround to run my app in IE11 ? Do i need to upgrade GWT and if yes then to which version supports IE11? I don't have to use "X-UA-Compatible=IE8" meta tag....Please help
最满意答案
与Web上的任何内容一样,您应该始终尝试运行最新版本,因为所有应用程序都会发生变化。 2.0.4已经5岁了!
所以是的,升级到最新版本的GWT(截至今天的2.7.0),并且当下一个版本将到来时(2.8,在几周内)也尝试升级。
作为一种解决方法,因为它可以在IE8中工作,所以您可能会要求IE11使用X-UA-Compatible值IE=EmulateIE8来模拟它。 但这只是一个临时的解决方法,因为下一个版本(Edge,即将在Windows 10中取代IE)将不再支持X-UA-Compatible ( Intranet区域除外)。 请参阅X-UA-Compatible文档顶部的警告以及Mirosoft发布的本声明 。 真正的解决方案是与GWT版本保持同步,就像使用浏览器版本保持最新一样。
As with anything on the Web, you should always try to run the latest version, because everything changes around your application. 2.0.4 is 5 years old already!
So yes, upgrade to the latest version of GWT (2.7.0 as of today), and when the next version will come (2.8, in a few weeks) try to upgrade as well.
As a workaround, because it works in IE8, you could probably ask IE11 to emulate it using an X-UA-Compatible with value IE=EmulateIE8. But that's only a temporary workaround, as the next version (Edge, coming in Windows 10 to replace IE) will no longer support X-UA-Compatible (except in the Intranet zone). See the warning at the top of the X-UA-Compatible doc and this announcement by Mirosoft. The real solution is to stay up-to-date with GWT versions, just like you stay up-to-date with browser versions.
更多推荐
IE,attachEvent,GWT,使用,电脑培训,计算机培训,IT培训"/> <meta name="descrip
发布评论