https://bugzilla.wikimedia.org/show_bug.cgi?id=27644

--- Comment #7 from Krinkle <krinklem...@gmail.com> 2011-02-23 11:20:45 UTC ---
(In reply to comment #6)
> +    return !( browserVersionCheck( 'MSIE', 6 )
> +        || browserVersionCheck( 'Chrome/', 1 )
> +        || browserVersionCheck( 'Firefox/', 2 )
> +        || browserVersionCheck( 'Safari', 3 )
> +        || browserVersionCheck( 'Opera', 9 )
> +    );
> 
> Should work then....

No because Opera also uses a slash, and, moreover, the release version in opera
browsers is after "Version/" not after "Opera/" (atleast in the current Opera).

-

Same thing with Safari " (... ) Version/5.0.3 Safari/533.19.4 (..) "

The Safari release version is 5.0.3, "533.19.4" is an internal code (presumably
a build number from Apple and/or of the WebKit engine specifically)

-

"Firefox/" would work I guess (including the slash in the split)

-

Chrome is tricky indeed. Apple released Safari but they're also behind WebKit
(although WebKit is open source, it's still backed by Apple in some ways) - so
the "Safari"-string gets in the face from time to time when using non-Safari
WebKit browsers.

See also the source of
http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/resources/jquery/jquery.client.js?view=markup

and look at:
http://ajax.googleapis.com/ajax/libs/jquery/1.5.0/jquery.js
It has some interesting stuff. Seperated over three sections (ctrl-f find
them):
// Useragent RegExp
and
uaMatch: function( ua ) { 
and
browserMatch.browser

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to