Search code examples
javascripttabindex

can't tab in SelectBoxIt


Hello my name is Shane,

I am coding a custom website. I have built a contact form and am using SelectBoxIt (http://gregfranko.com/jquery.selectBoxIt.js/) for my drop-down feature. I have several Input Fields, two buttons and one Select Box (drop-down). I have the form working perfectly, my issue is with the TabIndex. I have the correct tabindexs coded in each Input, but when I tab to the Select Box it gets ignored.

Here is the page: http://www.lightupco.com/contact.htm NOTE: you have to click the Envelope/Pen icon to reveal the form.

The only clue I have from researching a forum with similar issue, is it has something to do with the underlying UL throws the tab index off.

I'm not sure what code from my page to include here, to get help figuring this out?


Solution

  • Hey Shane I wrote SelectBoxIt. The reason your select box tabindex is getting ignored is because SelectBoxIt hides the original select box and replaces it with new HTML that is easier to style (a div element). Hence, the tabindex attribute is not being set on the visible drop down (the div element), only the hidden select box.

    If you don't mind creating an issue on Github, I would be happy to add a feature to SelectBoxIt that copies any tabindex attribute on the original select box to the new visible drop down. That should solve your issues.