Opened 9 years ago

Closed 8 years ago

Last modified 8 years ago

#13159 closed defect (fixed)

dojo.isOpera gives incorrect 9.8 version since Opera 10

Reported by: lewar Owned by: Rawld Gill
Priority: high Milestone: 1.7
Component: Loader Version: 1.6.1
Keywords: Cc:
Blocked By: Blocking:

Description

Opera 10 is the first browser which hit the double-digit version crisis.

Since then Opera's user agent string changed its form. Now it contains misleading prefix "Opera/9.80", which is similar to "Mozilla/5.0" in Firefox.

Examples of Opera's user agent string:

"Opera/9.52 (Windows NT 5.1; U; pl)"
dojo.isOpera == 9.52 <- OK!

"Opera/9.80 (X11; Linux i686; U; PLD/2.0 (Ac); pl) Presto/2.2.15 Version/10.01"
dojo.isOpera == 9.8 <- BAD

"Opera/9.80 (S60;SymbOS;OperaMobi/1209;U;pl) Presto/2.5.28 Version/10.1)"
dojo.isOpera == 9.8 <- BAD

"Opera/9.80 (X11; Linux x86_64; U; PLD/3.0 (Th); pl) Presto/2.8.131 Version/11.11"
dojo.isOpera == 9.8 <- BAD

"Opera/9.80 (Windows NT 5.1; U; pl) Presto/2.8.131 Version/11.11"
dojo.isOpera == 9.8 <- BAD

In order to detect a real Opera browser version (higher then 9.8), a "Version/11.11" suffix shoud be considered. This suffix can be extracted in a similar way as "Firefox/4.0.1" from user agent string.

Attachments (1)

sniff-opera.diff (649 bytes) - added by lewar 9 years ago.
My proposition of a patch for a current version from trunk

Download all attachments as: .zip

Change History (4)

Changed 9 years ago by lewar

Attachment: sniff-opera.diff added

My proposition of a patch for a current version from trunk

comment:1 Changed 8 years ago by Rawld Gill

Status: newassigned

comment:2 Changed 8 years ago by Rawld Gill

Resolution: fixed
Status: assignedclosed

(In [25548]) fixed opera sniff; fixes #13159; thanks lewar

comment:3 Changed 8 years ago by bill

Milestone: tbd1.7
Note: See TracTickets for help on using tickets.