I hate Internet Explorer  − 14 March, 2006

Over the past few days at work, I've been exposed to even more problems with IE than I could have ever imagined. The most recent issue is that, while IE supports nested tags when they're added via DOM methods, but when they're placed directly in the source HTML, its parser doesn't properly add them to the DOm after the first level. Sure, most people don't need to use nested forms, and I don't think the W3C would look very favorably on it (we did have our reasons), but it's just frustrating to know that it's somewhat supported, just not if done in a more convenient way. One other big problem I have with it is the fact that IE doesn't provide access to the DOM object prototypes. Mozilla and Safari offer this (though in slightly different ways), and it can be quite useful to add custom methods for navigating the document structure or performing other functions on a per-object basis. One particularly valuable use is adding a set of class management functions to make it easier to manage multiple classes on a given object with DOM functions (since ordinarily the W3C DOM only provides class information as a single string, which can be difficult to deal with). Unfortunately, IE doesn't provide a good way to do this. It does provide a roundabout way to do it, through the use of HTML Components, but since those have to be assigned with CSS, the best that can be done is assign it using the universal selector (*), which will assign methods to all elements. This, however, still leaves text nodes out of the running. While that may not be a problem for the class management scriptsw (since it'd be largely useless, if not impossible, to apply classes to text nodes), it would be a great time-saver to be able to provide DOM traversal methods to all nodes, text nodes included. One other nitpicky issue I ran into is the fact that when populating a set of nodes outside the document, there's some strange behavior when moving nodes into and out of the document. When cloning nodes out of the document, selects lose their selectedIndex value, which then has to be set manually using the original value in order to be of any use. Then, when re-inserting it into the document, checkboxes lose their value, regardless of what has been done for them between cloning and re-insertion. Interestingly, the checkbox values are actually intact immediately following the clone, unlike the selects. I don't think many people would run into this, but there are certainly times where dealing with forms in this manner would be necessary, and IE makes this process as painful as possible. Anyway, that's enough complaint for now. More later.

Posted on April 19, 2008. and has been viewed 31 times.     AddThis Social Bookmark Button





Bit11 Bit6 Bit12 Bit1 Bit7 Bit2 Bit3 Bit20 Bit15 Bit4 Rss






Have been here:

5067-75
Josh Shartzer
about 1 month ago