HighDots Forums  

User Agent Detection Logic

Javascript JavaScript language (comp.lang.javascript)


Discuss User Agent Detection Logic in the Javascript forum.



Reply
 
Thread Tools Display Modes
  #41  
Old   
Lasse Reichstein Nielsen
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 03:13 PM






"Fotios" <f_bass (AT) yahoo (DOT) com> writes:

Quote:
Anyone who can think straight can see how a browser like the one I have
described would make the detection style you are a proponent of a big
problem in many cases.
A browser that implements W3C DOM perfectly[1], but which maliciously
distorts proprietary IE features, will work perfectly with object
detection ... because you should always test for W3C DOM first.

/L
[1] Including widely accepted non-W3C objects that are not originated
at Microsoft, e.g., the global "document" and "window" variables.
--
Lasse Reichstein Nielsen - lrn (AT) hotpop (DOT) com
Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
'Faith without judgement merely degrades the spirit divine.'


Reply With Quote
  #42  
Old   
Jim Ley
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 03:30 PM






On Thu, 25 Sep 2003 23:25:17 +0100, "Fotios" <f_bass (AT) yahoo (DOT) com> wrote:

Quote:
A browser that implements W3C DOM perfectly[1], but which maliciously
distorts proprietary IE features, will work perfectly with object
detection ... because you should always test for W3C DOM first.

Have you noticed how you are suddenly on a "should" basis?
Well you're the perfect example of how people don't understand object
detection... what other word than SHOULD do you think Lasse should be
using? it can't be MUST, we have no control over people, so what
exactly do you suggest?

Jim.
--
comp.lang.javascript FAQ - http://jibbering.com/faq/



Reply With Quote
  #43  
Old   
Jim Ley
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 03:48 PM



On Thu, 25 Sep 2003 23:48:01 +0100, "Fotios" <f_bass (AT) yahoo (DOT) com> wrote:

Quote:

Well you're the perfect example of how people don't understand object
detection... what other word than SHOULD do you think Lasse should be
using? it can't be MUST, we have no control over people, so what
exactly do you suggest?

No, it should be SHOULD which is exactly my point. To make it more explicit
for you, gone is the certainty that object and property checking just works.
Of course it does work if it's written correctly, however your user
agent sniffing cannot be written correctly in such manner that works
with even known browsers, you're relying on some very weird
hypothetical browser that does not exist - making it with IE would be
pretty easy.

Quote:
BTW, the first Fudgilla Service Pack was released. Fudgilla will now check
for instances of proprietary Microsoft objects/properties anywhere in the
script and if it finds even one it will mess up the script anyway.
So it will "mess up the script" across the proprietary Microsoft
object like "document" then? and pray tell me how this is done, the
code analysis methods would be really useful to me for other things,
any language is good.

Jim.
--
comp.lang.javascript FAQ - http://jibbering.com/faq/



Reply With Quote
  #44  
Old   
Douglas Crockford
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 04:14 PM



This thread grows tiresome.


Reply With Quote
  #45  
Old   
Richard Cornford
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 04:22 PM



"Fotios" <f_bass (AT) yahoo (DOT) com> wrote

<snip>
Quote:
"code analysis methods" when all that would be needed is
simple substring detection?
And now a browser that supposedly was created to promote web standards
is in breach of ECMA 262.

Richard.




Reply With Quote
  #46  
Old   
Jim Ley
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 04:33 PM



On Fri, 26 Sep 2003 00:12:17 +0100, "Fotios" <f_bass (AT) yahoo (DOT) com> wrote:

Quote:
"code analysis methods" when all that would be needed is simple substring
detection?
no, that doesn't work...

all='getElementById'
document[all]()

or even just

document.fred

that uses IE proprietary, yet ain't gonna be found by simple substring
detection.

Jim.
--
comp.lang.javascript FAQ - http://jibbering.com/faq/



Reply With Quote
  #47  
Old   
Fotios
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 05:10 PM



Richard,

your lengthy mantras serve to prove my point perfectly. On the other hand
your attempt to prove that my point is of no real significance is pathetic.
Anyone who can think straight can see how a browser like the one I have
described would make the detection style you are a proponent of a big
problem in many cases. Perhaps I should I write an FAQ for you in order to
understand.

F.



Reply With Quote
  #48  
Old   
Fotios
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 05:25 PM




Quote:
A browser that implements W3C DOM perfectly[1], but which maliciously
distorts proprietary IE features, will work perfectly with object
detection ... because you should always test for W3C DOM first.
Lasse,

Have you noticed how you are suddenly on a "should" basis?

F.




Reply With Quote
  #49  
Old   
Fotios
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 05:48 PM





Quote:
Well you're the perfect example of how people don't understand object
detection... what other word than SHOULD do you think Lasse should be
using? it can't be MUST, we have no control over people, so what
exactly do you suggest?
No, it should be SHOULD which is exactly my point. To make it more explicit
for you, gone is the certainty that object and property checking just works.

BTW, the first Fudgilla Service Pack was released. Fudgilla will now check
for instances of proprietary Microsoft objects/properties anywhere in the
script and if it finds even one it will mess up the script anyway.

F.





Reply With Quote
  #50  
Old   
Jim Ley
 
Posts: n/a

Default Re: User Agent Detection Logic - 09-25-2003 , 06:01 PM



On Fri, 26 Sep 2003 01:50:29 +0100, "Fotios" <f_bass (AT) yahoo (DOT) com> wrote:

Quote:
it is obvious that it does not have to be a "catch all" right away.
replies go after snipped quotes, you showed you knew it before, please
try again.

Quote:
Can't you see that you cannot win this argument as long as I control
Fudgilla?
You constrained yourself to a W3 DOM and ECMAScript compliance, if you
want to throw that away, of course, nothing will work, but with those
requirements in, we can gracefully degrade any script with object
detection.

Jim.
--
comp.lang.javascript FAQ - http://jibbering.com/faq/



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.