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

IE 9/10 in Windows7 desktop will be detected wrong as a 'tablet' #7

Open
yanhuiyi opened this issue Aug 20, 2013 · 3 comments
Open

Comments

@yanhuiyi
Copy link

The userAgent sting in some IE browers 9 or 10 in Windows 7 will generate string differently as

"Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; Trident/6.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; BRI/2; .NET4.0C; Tablet PC 2.0; MALC)"

Or

"Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; Trident/6.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0)" 

if you filter out tablet first with

ua.match(/iPad/i) || ua.match(/tablet/i) && !ua.match(/RX-34/i) || ua.match(/FOLIO/i) ? 'tablet'

you report it desktop PC wrong with former UA.

@yanhuiyi
Copy link
Author

Is it possible to be fixed by something like:

ua.match(/tablet/i) && !ua.match(/tablet pc/i)

@iamdustan
Copy link
Contributor

Pull request welcome if you can isolate the fix to that. I don’t have any Windows devices to manually test.

I started writing a comprehensive test suite a while back, but I’m pretty sure I lost it on when replacing my hard drive.

@WilHall
Copy link

WilHall commented Dec 19, 2013

I can confirm that I have the same issue on Windows 7 running IE9 or IE10

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

No branches or pull requests

3 participants