Chapter 12. Case Study: Style Your select with the DOM

by Aaron Gustafson

For the last few years, I've had somewhat of an unhealthy obsession with the select element. Perhaps "unhealthy" is a bit too strong (or gives you the wrong idea), but let's just say that I've done a lot of thinking about select elements and what I would do differently if I were in charge.

I'm not sure when it all started. Perhaps it was when I first discovered the truly elegant way Internet Explorer 5 on Mac (IE5/Mac) handles select elements containing organizational optgroup elements (see Figure 12-1, left). Or maybe it was when I really started to dive into CSS and realized that I couldn't so much as change the border-style from the ugly default (it's inset in most browsers ...

Get AdvancED DOM Scripting: Dynamic Web Design Techniques now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.