Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

appversion detection fails on IE10 #390

Open
GoogleCodeExporter opened this issue May 23, 2015 · 1 comment
Open

appversion detection fails on IE10 #390

GoogleCodeExporter opened this issue May 23, 2015 · 1 comment

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1.Load/execute script in IE 10
2.
3.

What is the expected output? What do you see instead?

Error: unable to get property of '1' of undefined or null reference


What version of the product are you using? On what operating system?

2.1(beta4) on Windows -- especially with Adobe Contribute which somehow ignores 
the IE comments to skip the script if over IE8 even though it's embedding IE10. 
Will probably not affect most users, but it was driving my clients using 
Contribute nuts ;-)


Please provide any additional information below.

The regular expression in the statement beginning line 6, col 84 supports only 
single-digit major version numbers. Adding a + character as shown in the 
following (and in the attached patched IE9.js) will support multi-digit major 
numbers as well as single.

var t=h.appVersion=navigator.appVersion.match(/MSIE (\d+\.\d)/)[1]-0;

Original issue reported on code.google.com by [email protected] on 15 Aug 2013 at 3:42

Attachments:

@GoogleCodeExporter
Copy link
Author

IE11 has changed the navigator.appVersion string, so the necessary regexp must 
include an alternation to find both the old "MSIE ##.#" and the new "rv:##.#" 
variations:

navigator.appVersion.match(/(?:MSIE |rv:)(\d+\.\d)/)[1]

Original comment by [email protected] on 5 Dec 2013 at 2:50

Attachments:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant