Aaron Gustafson is putting together a series of articles on how to make select elements stylable. In essence, what his work does is take the select out of the DOM and replace it with a ul, and then add script and CSS to make that ul work like a dropdown list. The advantage this gives is clear to everyone who’s ever complained about how selects aren’t stylable! The series has only just started, and there are a few concerns — the new element can’t be tabbed to, and doesn’t respond to keyboard events — but Aaron promises that part 2 will cover accessibility issues.
The script uses similar techniques to the Suckerfish dropdowns, applying “hover” and “selected” classes to various parts of the ul to provide hooks for styling (since IE doesn’t support :hover on things that aren’t links). This should be a useful technique to watch!
Related posts:
- The Right Way to Make a Dropdown Menu Whether you love them or hate them, it seems that...
- Progressive Enhancement and Graceful Degradation: Making a Choice How should you choose between progressive enhancement or graceful degradation...
- Making A Clipping Mask With Text In Photoshop Jennifer shows you how to make a clipping mask using...
- Brainstorming: Making Sense and Taking Action Alyssa wraps up her series on brainstorming with a step-by-step...
- Are You Making the Grade? How To Ask Clients for Feedback Client satisfaction surveys are an important part of freelancing and...







Thanks for the heads up Stuart, I wonder what browsers it’ll be compatible with *wonders off to read*
April 16th, 2005 at 5:28 am
He didn’t add a document.onclick=”hide the menu”, so if you click the drop down and then click somewhere else, it doesn’t disappear. Other than that, cool.
April 16th, 2005 at 8:57 am
Ick! It doesn’t even work in Opera. I hate Firefox only coders…
April 16th, 2005 at 9:30 am
Works fine here in Opera (7.51), Firefox and IE.
April 16th, 2005 at 9:11 pm
Would be nice if it layered over the top of the form rather than taking up space in the page flow when its expanded.
April 17th, 2005 at 6:24 pm
Looks great, but I would agree with mrsmiley. Also, keyboard support is a must. Should be able to tab to the control and select with keyboard.
April 21st, 2005 at 2:29 pm
Very stylish! :D Would be nice to read about the accessibility issues.
April 28th, 2005 at 8:21 pm
Interesting, I published a similar piece some time ago:
http://icant.co.uk/forreview/tamingselect/
May 10th, 2005 at 8:59 am
Your article is very informative and helped me further.
Thanks, David
February 4th, 2007 at 10:06 am