WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: alternative to use of onChange in select menus

for

From: Tim Harshbarger
Date: Jun 9, 2011 6:09AM


It's been a while since I did this, but I know I once had a working example of a quick nav combobox that allowed people using the keyboard to select an item from the combobox and then click a go button while allowing people using the mouse just to expand the combobox and then select an item to go to the new page.

What I did is set up a combobox with a go button that was just basically a standard web form that was processed by the server. Then I added a click event to the combobox where the first mouse click just has the combobox expand and the second mouse click causes the user to be sent to the new page. If no item had been selected, then nothing happens.

I am uncertain I still have the code for that one laying around. I was just trying to generate a number of possible solutions for a similar problem to yours and it was just one of the ideas I tossed together. I do remember that the coding wasn't that difficult.
I think I had two