![]() | |
![]() |
| | Thread Tools | Display Modes |
#21
| |||
| |||
|
|
In comp.lang.javascript message <c7ebf289-542a-4c87-a323-a67f0bbf1bd0@m2 5g2000vbi.googlegroups.com>, Sat, 31 Oct 2009 17:36:38, David Mark dmark.cins... (AT) gmail (DOT) com> posted: On Oct 31, 6:21*pm, Dr J R Stockton <reply0... (AT) merlyn (DOT) demon.co.uk wrote: In comp.lang.javascript message <e4WdnckhUoAkZXbXnZ2dnUVZ8s- dn... (AT) brightview (DOT) com>, Sat, 31 Oct 2009 08:43:31, Swifty steve.j.sw... (AT) gmail (DOT) com> posted: I know that detecting the browser is frowned upon here, but I have a need to identify specifically Internet Explorer 6. Testing either * * (0.007).toFixed(2) or * * S = "3000000000000000000000000" ; parseFloat(S+".0")/parseFloat(S) will identify IE : the second in at least IE 4 to IE 8, and the first in all versions from the introduction of toFixed to IE 8. *Use those in addition to conditional compilation, and you have belt-and-braces. There is, I suppose, some risk of MS correcting those bugs; but that will not worry you. What should worry you is other implementations with similar bugs. Who else would do that? *Only the biggest American organisations can consistently sustain that level of incompetence. |
#22
| |||
| |||
|
|
Thomas 'PointedEars' Lahn wrote: http://my-debugbar.com/wiki/IETester/HomePage An installation of Standalone IE or IE Tester does not touch the existing DLLs, it provides its own located in its program directory. However, IE Tester allows you to use the existing ones when and if it is conventient with the "Default IE" browsing tab. |
#23
| |||
| |||
|
|
On Nov 1, 5:17*pm, Dr J R Stockton <reply0... (AT) merlyn (DOT) demon.co.uk wrote: In comp.lang.javascript message <c7ebf289-542a-4c87-a323-a67f0bbf1bd0@m2 5g2000vbi.googlegroups.com>, Sat, 31 Oct 2009 17:36:38, David Mark dmark.cins... (AT) gmail (DOT) com> posted: On Oct 31, 6:21*pm, Dr J R Stockton <reply0... (AT) merlyn (DOT) demon.co.uk wrote: In comp.lang.javascript message <e4WdnckhUoAkZXbXnZ2dnUVZ8s- dn... (AT) brightview (DOT) com>, Sat, 31 Oct 2009 08:43:31, Swifty steve.j.sw... (AT) gmail (DOT) com> posted: I know that detecting the browser is frowned upon here, but I have a need to identify specifically Internet Explorer 6. Testing either * * (0.007).toFixed(2) or * * S = "3000000000000000000000000" ; parseFloat(S+".0")/parseFloat(S) will identify IE : the second in at least IE 4 to IE 8, and the first in all versions from the introduction of toFixed to IE 8. *Use those in addition to conditional compilation, and you have belt-and-braces. There is, I suppose, some risk of MS correcting those bugs; but that will not worry you. What should worry you is other implementations with similar bugs. Who else would do that? *Only the biggest American organisations can consistently sustain that level of incompetence. Well, only an incompetent developer would infer anything from that bug (except that toFixed is broken). It certainly isn't a good inference for IE as they could fix that bug at any time |
|
and other browser developers are certainly capable of such mistakes. |
|
In fact, other browsers are known to replicate IE bugs in quirks mode. |
#24
| |||
| |||
|
|
David Mark <dmark.cins... (AT) gmail (DOT) com> writes: […] The OP wants to target 6 and we know that XMLHttpRequest was not introduced until 7. *Combine that with detection of ActiveXObject, window.external, document.documentElement.filters, document.documentElement.style.filter, document.expando, etc. and you can be pretty sure you've got IE6 If it *has* to be script based for some reason, I’d rather combine that with conditional compilation. |
|
And then only if a false positive would just result in an unnecesary performance hit (e.g. using filters where it isn’t necessary), because we also know that the native XMLHttpRequest object can be disabled in the IE 7/8 preferences. |
#25
| |||
| |||
|
|
In comp.lang.javascript message <e1970d70-ed13-4660-a0e1-6941443ada91@k4 g2000yqb.googlegroups.com>, Mon, 2 Nov 2009 03:21:16, David Mark dmark.cins... (AT) gmail (DOT) com> posted: On Nov 1, 5:17*pm, Dr J R Stockton <reply0... (AT) merlyn (DOT) demon.co.uk wrote: In comp.lang.javascript message <c7ebf289-542a-4c87-a323-a67f0bbf1bd0@m2 5g2000vbi.googlegroups.com>, Sat, 31 Oct 2009 17:36:38, David Mark dmark.cins... (AT) gmail (DOT) com> posted: On Oct 31, 6:21*pm, Dr J R Stockton <reply0... (AT) merlyn (DOT) demon.co.uk wrote: In comp.lang.javascript message <e4WdnckhUoAkZXbXnZ2dnUVZ8s- dn... (AT) brightview (DOT) com>, Sat, 31 Oct 2009 08:43:31, Swifty steve.j.sw... (AT) gmail (DOT) com> posted: I know that detecting the browser is frowned upon here, but I havea need to identify specifically Internet Explorer 6. Testing either * * (0.007).toFixed(2) or * * S = "3000000000000000000000000" ; parseFloat(S+".0")/parseFloat(S) will identify IE : the second in at least IE 4 to IE 8, and the first in all versions from the introduction of toFixed to IE 8. *Use thosein addition to conditional compilation, and you have belt-and-braces. There is, I suppose, some risk of MS correcting those bugs; but that will not worry you. What should worry you is other implementations with similar bugs. Who else would do that? *Only the biggest American organisations can consistently sustain that level of incompetence. Well, only an incompetent developer would infer anything from that bug (except that toFixed is broken). *It certainly isn't a good inference for IE as they could fix that bug at any time The OP implied rather strongly that it is IE6 which he wants to detect. MS are unlikely to fix that now. |
|
and other browser developers are certainly capable of such mistakes. Of mistakes, yes. *But Microsoft outclasses the rest in this respect. |
|
*In fact, other browsers are known to replicate IE bugs in quirks mode. Some IE bugs. *Mostly ones with visual effect? |
#26
| |||
| |||
|
|
If it *has* to be script based for some reason, I’d rather combine that with conditional compilation. Fine, as long as you aren't going by the script engine version. |
![]() |
| Thread Tools | |
| Display Modes | |
| |