on writing css...
Thursday, March 23, 2000, at 12:22PM
By Eric Richardson
I've been working on updating two of the eWorld sites in the past couple of days, and have been trying to use CSS positioning and styles to eliminate some code bloat. Along the way I've come to realize just how aweful current implementations of CSS are.
For example, on one site I define line-spacing to be 1.2em. It works great on text, but for some reason Netscape sees that and decided that images aren't exceptions to this rule, and crumples everything together (overlapping some images). IE and Mozilla both render that page fine.
On the other site I'm trying to use CSS to do a menu that will line up with the image about it. Sounds easy, right? JUst use absolute positioning... The problem comes when I try to add margins to the box... Mozilla seems to think that margins are added to the width of the text box (ie the width of the box is the specified width plus the margin widths), while IE thinks the text gets the specified width minus the margins (which seems logical, but I don't know what the spec specifies). Netscape just ignores myt width and fits the text.
I think I'm just going to design for Mozilla and tell people using other browsers that I don't really care...