<br><br>On Thu, Aug 11, 2011 at 3:25 AM, Eli Barzilay <<a href="mailto:eli@barzilay.org">eli@barzilay.org</a>> wrote:<br>> On Aug 10, 2011, at 11:33 PM, Guillaume Marceau <<a href="mailto:gmarceau@gmail.com">gmarceau@gmail.com</a>> wrote:<br>
>> Does the combo box auto detect the<br>>> downloader's platform for the User-Agent header.<br>><br>> Yes, in some cases when it's possible to make a guess.<br>><br><br>I found this Stackoverflow article:<br>
<br> <a href="http://stackoverflow.com/questions/1741933/detect-64-bit-or-32-bit-windows-from-user-agent-or-javascript">http://stackoverflow.com/questions/1741933/detect-64-bit-or-32-bit-windows-from-user-agent-or-javascript</a><br>
<br><div>which says that the following code</div><div><br></div><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;"><div>deployJava.isWin64OS = function() {</div><div> return navigator.userAgent.indexOf('WOW64')>-1 || window.navigator.platform=='Win64';</div>
<div>};</div></blockquote><div><br></div><div>will return one of these:</div><div><br><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;">64 bit MacOS + 64 bit Safari or 32 bit Chrome:<br>
window.navigator.platform=MacIntel<br><br>32 bit windows + safari:<br>window.navigator.platform=Win32<br><br>64 bit Windows + 64 bit IE:<br>window.navigator.platform=Win64<br>window.navigator.cpuClass=x64<br><br>64 bit Windows + 32 bit IE:<br>
window.navigator.platform=Win32<br>window.navigator.cpuClass=x86<br><br>64 bit Windows + 32 Firefox (or Chrome):<br>window.navigator.platform=Win32<br><br>32 bit linux mint (i686) + firefox:<br>window.navigator.platform=Linux i686<br>
<br>64 bit Ubuntu (x86_64) + 32 bit Chrome:<br>window.navigator.platform=Linux i686<br><br>64 bit Ubuntu + 64 bit Epiphany:<br>window.navigator.platform=Linux x86_64<br><br></blockquote>In the ambiguous cases, you can get additional information by checking for flash. Because Adobe doesn't support flash player on x64 browsers, if detection is successful then it is definitely a 32 bit browser, if not, then the request came from either a 32 bit browser without flash plugin or from a 64 bit browser. </div>
<div><br></div><div><br></div><div><br></div>