...

View Full Version : NS, IE6, IE7, Mozilla? What standards?



ScottInTexas
05-13-2007, 02:55 PM
While looking through the code that has been written by sime of you gurus I see a lot of "if (ie4||ie5||ns5)" and the liked to access the elements in a document. Now that there is IE7 and, no doubt, several other upgrades in NS how do you find out what changes need to be made to code? What references do you guys use to see if what you write will be OK? I tried to run NS on my computer but it never did work right so I uninstalled it.

I use the reference in the w3c DOM but I kknow I have written questions here asking "why doesn't this work..." when I have tried addressing elements and it must have to do with the variation in the w3c DOM and ie6 or ie7.

_Aerospace_Eng_
05-13-2007, 05:56 PM
A lot of us don't support any IE browser lower than version 5.5. I think the best method is to test for a certain object. The IE6 and IE7 dom are pretty similar. Its JS engine might support a little more modern functions not sure.

felgall
05-13-2007, 08:37 PM
While looking through the code that has been written by sime of you gurus I see a lot of "if (ie4||ie5||ns5)" and the liked to access the elements in a document.

You will only find code like that in long outdated scripts and those written by newbies who haven't learnt JavaScript properly yet. Modern JavaScript coding uses feature sensing to test if the browser supports the code you are using regardless of which browser it is. The only time any form of browser detection is used is to test for Internet Explorer for those instances where JScript insists on a different version of a statement from that used by JavaScript and where there is no feature that can be tested for as both JScript and JavaScript support the feature - just in different ways.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum