Thank you very much for the help. This is really an urgent question for
me.
Melvin
<define-property name="user.agent"
values="ie6,moz,oldmoz,safari,opera"/>
<property-provider name="user.agent"><![CDATA[
var ua = navigator.userAgent.toLowerCase();
if (ua.indexOf("opera") != -1) {
return "opera";
}
else if (ua.indexOf("safari") != -1) {
return "safari";
}
else if ((ua.indexOf("msie 5.5") != -1) ||
(ua.indexOf("msie 6.0") != -1) ||
(ua.indexOf("msie 7.0") != -1)) {
return "ie6";
}
else if (ua.indexOf("mozilla") != -1) {
var geckoIdx = ua.indexOf("gecko/");
if (geckoIdx == -1)
return "oldmoz";
var spaceIdx = ua.indexOf(" ", geckoIdx);
if (spaceIdx == -1)
spaceIdx = ua.length;
var version = parseInt(ua.substring(geckoIdx + 6, spaceIdx));
if (version < 20051107) // Firefox1.5's Gecko version
return "oldmoz";
return "moz";
}
return "unknown";
]]></property-provider>
The kitchen sink demo works perfectly in IE 5.5, as do all AJAX tests I
have performed.
The only drawback I have experienced doing this is a serious one. IE
5.5 cannot be put into strict mode, so positioning and size methods on
widgets and in DOM.java will be inconsistent due to the different box
models. How big of a deal this is depends on your application.