GWT 2.3 - ie8 user agent is recognized as ie6

238 views
Skip to first unread message

Miroslav Genov

unread,
Jun 23, 2011, 7:51:36 AM6/23/11
to google-we...@googlegroups.com
Hello,
I'm encountering a strange issue which is causing IE8 user agent to be recognized as IE6. 

My app is compiled with:
<set-property name="user.agent" value="ie8" />

And my page contains the following definition:
<meta http-equiv="X-UA-Compatible" content="IE=8">
But when I compile my app to js, the browser is showing alert that version of my app is for "ie8", but my browser version is ie6, but my version of IE is 8.0.6001 and also the compatibility mode is disabled. Any idea what is causing this issue ? 

Also there is and another issue. If I have multiple user agents, the application generates only permutations for the latest one that is specified. Any idea how can I specify several permutations to be created ?
<set-property name="user.agent" value="ie8" />
<set-property name="user.agent" value="safari" /> 
// only safari is generated 

<set-property name="user.agent" value="ie8, safari" />  // fails 
If I use the following definition, the UserAgentGenerator fails with BadPropertyValueException

Miroslav Genov

unread,
Jun 23, 2011, 8:26:40 AM6/23/11
to google-we...@googlegroups.com
Here is header information that comes from my browser:
Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.2; Trident/4.0; .NET CLR 1.1.4322)

Thomas Broyer

unread,
Jun 23, 2011, 12:46:11 PM6/23/11
to google-we...@googlegroups.com


On Thursday, June 23, 2011 1:51:36 PM UTC+2, Miroslav Genov wrote:
Hello,
I'm encountering a strange issue which is causing IE8 user agent to be recognized as IE6. 

My app is compiled with:
<set-property name="user.agent" value="ie8" />

And my page contains the following definition:
<meta http-equiv="X-UA-Compatible" content="IE=8">
But when I compile my app to js, the browser is showing alert that version of my app is for "ie8", but my browser version is ie6, but my version of IE is 8.0.6001 and also the compatibility mode is disabled. Any idea what is causing this issue ?

No idea, but just to make sure: hit F12 to open IE's Developer Tools, and check whether it runs in "IE8 Standards Mode". If that's not the case, then GWT is right, and you have to change your page so that IE runs in "IE8 mode".
 
Also there is and another issue. If I have multiple user agents, the application generates only permutations for the latest one that is specified. Any idea how can I specify several permutations to be created ?
<set-property name="user.agent" value="ie8" />
<set-property name="user.agent" value="safari" /> 
// only safari is generated 

<set-property name="user.agent" value="ie8, safari" />  // fails 
If I use the following definition, the UserAgentGenerator fails with BadPropertyValueException

Try removing the space after the coma. This is the correct syntax, and at least it worked in GWT pre-2.3, before IE9 support was introduced and the user-agent check was overhauled.
Reply all
Reply to author
Forward
0 new messages