Tech Talk

Permanent link to CSS Bugs CSS Bugs

Thursday, June 13, 2002

Well, I'm into CSS in a big way now. I'm throwing away tables left and right, and discovering all sorts of new quirks. I don't see it so much as things not working, as it's a new set of working parameter to feel out.

Speaking of quirks, Internet Explorer was working as "expected" until I found out how to add the DOCTYPE tag to force it into compatability mode. Here I thought that the differences between IE and the other browsers I test (Netscape, Opera, Konqueror) was just brand-name difference. Nope. Turns out the non-IE browsers were actually doing CSS right, for the most part, and now IE does, too.

Just to start positive, here are some of the things I've found that I love about CSS:

  • Site-wide changes controlled from one (or a few) central CSS configuration files
  • Noticeably faster loading, and in logical order instead of top to bottom
  • Much easier to accomplish rollover effects, without even having to use any images either
  • Ability to have printed sheets look different than the screen. I haven't done much with this, but it means stuff like print can have smaller text, remove hyperlinks (duh! ever try clicking paper?), fix margins, etc.
  • Way, way easier to build bordered boxes - sooo, so much nicer than nesting tables up the wazoo.
  • Being able to style stuff based on structure is really cool, because I can apply formatting after the fact without having to go stick a class attribute on everything! Like, make all H2s in menublock DIVs be green. Nice.

Ok, fine. Even so, I have found a few annoying things that may or may not be fixable:

  • Designing in CSS-compatible mode is suprisingly tricky. The concept seems so simple, but then stuff just doesn't flow like I expect. It actually worked much more intuitively (for me anyway) when I was working with IE in quirks mode.
  • An IE-specific, really annoying behavior: try selecting a paragraph of text. I can't! It starts from the beginning of the DIV. Opera and Netscape behave themselves - why can't IE?
  • I can left-align or right-align a DIV, but center? No way. Not like I do that much anyway, but still, it's annoying not to be able to.
  • I really don't like reading how to work around browser bugs by exploiting other bugs. That doesn't make any sense to me - what happens when you have another combination of bugs that breaks your buggy with-bugs bug fix? This is done a lot to get around IE5's broken box model. I say, just make a design that goes with the flow whether or not your boxes get a little bigger or smaller.

In any case, there are a whole new set of tricks and best practices to know in this new world of table-less layout. But it's worth it all when your site is accessible to all people on all devices, just the way it's supposed to be.


LaRocque Family