Same here with Chrome on OSX Mavericks. I imagine it can only a subset of known windows versions and if it can't detect yours it just assumed you have Windows 8.1
Very simple explanation: Microsoft is using a group of if/else if conditions, or some switch/select case structure, and it checks the user agent for every version of Windows except 8.1... 8.1 is the "default" (catch all) case, or the else in the end of the if structure. Basically who coded this page assumed (hopefully on accident) that the only OS in the world with Web browsing capabilities is Windows, and that if the version doesn't match any of the previous Windows versions, then it must be Windows 8.1.
Had this been some years ago, and I would say the page was relying on some ActiveX control to check the OS version, and that on error, "Windows 8.1" would be shown. Fortunately, even Microsoft seems to have abandoned ActiveX.
My Linux setup is now very offended because a web page called it names.
Perhaps they are simply assuming Windows 8.1 and everyone else have the best support for web standards and they only need to check if you are some other version of Windows in order to deal with them specifically.
Or they only need to customize content based on Windows versions and if you're using the latest or something non-MS, you probably want to see stuff about the latest Windows version.
That all makes sense if they were only determining the OS version for internal purposes, in order to filter the content as you said (still, it's great to let users know about it, otherwise people may get confused as to why they see different content on different machines/browsers).
Since this is a public page, with the title "Which Windows operating system am I running?", I think the right thing to show when the user is not running Windows is, well, "You are not running Windows". That would clearly inform users, who may not be aware, of the fact that their OS is not Windows (and that, most likely, that website will have nothing to help them with using their current OS). Another alternative would be "Can't determine Windows version". Anyway, they way things are now, that page is definitely wrong.
A better question would be: why are you visiting a Microsoft website to indicate your operating system, when you clearly already know which operating system you are running, which is not even from Microsoft in the first place!?
Because this shows the difficulty in using user agent strings to determine the client OS. This sort of thing is common when offering downloads, for example, so the user doesn't have to pick which link to click, they just get a "download now!" link that's crafted for their specific OS.
Probably neither, it could be shortsightedness, or simply a tool that their tech support (or other help forums) use for people who do not know what OS they are using.
There are A LOT of people I have met through the years who could not tell the OS they were using. They'd not even be able to tell any Win OS, Linux distros or Mac OS versions apart.
Sure whoever built the page could assume that someone may take their over simplifications as a sign of incompetence.
Realistically though, on one hand users/developers/entrepreneurs/wantrepreneurs/etc could take stock of the simplicity of the tool (for people who need to find out what Win OS they use) OR on the other we could bash 'em for not catering to the other markets.
Ignoring the latter in no way demonstrates incompetence.
Is that a rhetorical question? I was curious whether they will correctly determine my OS. Frankly, I was expecting something like "you are not using Windows".
But, in reality, yours not a better question. The Microsoft tool could, obviously and easily, detect non-Microsoft operating systems and report them as such.
It is looking at User-Agent header for "Windows NT\ ?\d\.\d" string and only listed known recent Windows NT versions (from Windows XP), otherwise it will return "Windows 8.1". Tested this with:
curl -H "User-Agent: Windows NT 5.1" http://windows.microsoft.com/en-us/windows/which-operating-system
Results:
NT 5.1 - Windows 8.1
WindowsNT 5.1 - Windows 8.1
Windows NT 5.1 - Windows 8.1
Windows NT - Windows 8.1
Windows NT5.1 - Windows XP
Windows NT 5.0 - Windows 8.1
Windows NT 5.1 - Windows XP
Windows NT 5.2 - Windows 8.1
Windows NT 6.0 - Windows Vista
Windows NT 6.1 - Windows 7
Windows NT 6.2 - Windows 8
Windows NT 6.3 - Windows 8.1
Windows NT 6.4 - Windows 8.1
Windows Linux NT 5.1 - Windows 8.1
Well its meant to answer the question: "Which Windows operating system am I using?", so clearly OS X, Android, Chrome OS are all don't care states. Why were you expecting anything else?
You offer a tool that's directed at a certain group of people, namely those who are running Windows (which is apparent by the question it seeks to answers, "Which WINDOWS operating system am I running?") Then some mac user struts in, takes off his Wayfarers and goes, "Let's see what it will do when I check what version of Windows my MAC is running heh heh heh -- OH LOOK AT THOSE IDIOTS IN REDMOND! THEY 'CLAIM' I AM ON WIN8.1! WHAT MORONS. Market Share Conspiracy Rabble Rabble"... and so on.
It's like a dude signing up for a Gynecologist appointment online and then questioning why they 'claim' you are a woman in the background questionnaire.
I mean, come the on... Is this really trending at #2?
I think it's just a very public example of shitty coding. No decent code review should have allowed a catch-all condition to default to Windows 8.1 instead of "Unknown" or "Other" or some such. It's just a sad lack of attention to detail in a very public-facing way.
Well how many people using non-windows OS do you expect to go to Microsoft's website to check for what Windows version they are using? It not lack of attention to detail, it is a waste of time trying to implement a complex User Agent parsing for that 1 in a million who decides to do it for fun.
There may have been a number of other factors at play that led to the decision to have windows 8.1 as the default. I wouldn't immediately jump to "shitty code" as the culprit here, especially when the tool works exactly as it should for it's intended audience. It may have been something as simple as developing this tool before having confirmation as to which user-agent win 8.1 would use at time of launch (is it be 5.2? nope, bumped up to 5.3. Good thing we put in that fallback before pushing into production!) or evaluating the ROI on supporting an 'other/unknown' fallback with additional development.
One may consider putting resources toward developing code for a user-base that provides no return on the development investment is 'shitty coding'.
48 comments
[ 5.1 ms ] story [ 109 ms ] thread(Yes, I know, it's the Linux kernel, just fun that it matches the number of that OS)
But that's a strange way of saying Linux lol
Its either hardcoded or refuses to acknowledge the existence of an operating system other than Windows ;)
All the versions of Windows I tested work right, but then anything else just returns Windows 8.1.
Had this been some years ago, and I would say the page was relying on some ActiveX control to check the OS version, and that on error, "Windows 8.1" would be shown. Fortunately, even Microsoft seems to have abandoned ActiveX.
My Linux setup is now very offended because a web page called it names.
Or they only need to customize content based on Windows versions and if you're using the latest or something non-MS, you probably want to see stuff about the latest Windows version.
Since this is a public page, with the title "Which Windows operating system am I running?", I think the right thing to show when the user is not running Windows is, well, "You are not running Windows". That would clearly inform users, who may not be aware, of the fact that their OS is not Windows (and that, most likely, that website will have nothing to help them with using their current OS). Another alternative would be "Can't determine Windows version". Anyway, they way things are now, that page is definitely wrong.
Probably neither, it could be shortsightedness, or simply a tool that their tech support (or other help forums) use for people who do not know what OS they are using.
There are A LOT of people I have met through the years who could not tell the OS they were using. They'd not even be able to tell any Win OS, Linux distros or Mac OS versions apart.
Sure whoever built the page could assume that someone may take their over simplifications as a sign of incompetence.
Realistically though, on one hand users/developers/entrepreneurs/wantrepreneurs/etc could take stock of the simplicity of the tool (for people who need to find out what Win OS they use) OR on the other we could bash 'em for not catering to the other markets.
Ignoring the latter in no way demonstrates incompetence.
But, in reality, yours not a better question. The Microsoft tool could, obviously and easily, detect non-Microsoft operating systems and report them as such.
https://en.wikipedia.org/wiki/Internet_Explorer_for_UNIX
It's like a dude signing up for a Gynecologist appointment online and then questioning why they 'claim' you are a woman in the background questionnaire.
I mean, come the on... Is this really trending at #2?
One may consider putting resources toward developing code for a user-base that provides no return on the development investment is 'shitty coding'.
You must be new to HN or how Microsoft stories are treated here. Its a bit like how Obama stories are treated on Fox News.