[thelist] Spot the Error

James Aylard webmaster at equilon-mrc.com
Tue Oct 16 13:04:52 2001


    I'd like to correct a point that I made earlier about Netscape 4.x and
class names that contain underscores:

>     Technically, it's not an error. But Netscape 4.x ignores class names
> that contain underscores. Or, more accurately -- and more bizarrely -- it
> treats the underscores as though they are hyphens.

    I realized after further testing that Netscape 4.x (tested on version
4.77, Win2K) does accept the use of the underscore character within classes,
but that it *may* treat underscores as hyphens -- as it will also treat
hyphens as underscores. Essentially, both characters seem interchangeable.
And so, a class name of "td_New" will be equivalent to "td-New".
    Netscape 6.0x/Mozilla 0.8x, on the other hand, do not recognize
underscores within class names (this was corrected in Netscape 6.1 and
Mozilla 0.9x). Last I checked, Opera 5.x didn't support underscores in class
names, either.
    So, underscores in class names should be used with caution, and their
quirkiness should be understood.

James Aylard