DataTables logo DataTables

via Ad Packs
datatable search input tabindex is wrong
  • gdwolgastgdwolgast
    Posts: 4
    I have a jsp page that has 3 datatables. It also has several tabbable controls (input, anchors, etc) separate from the tables as well as anchors within the tables. I have tabindex on all the tabbable controls. When tabbing through the rendered document, the search inputs on the 3 tables are the last items tabbed. Is there a way to get the search boxes to be in tab order by giving them an explicit tabindex?
  • allanallan
    Posts: 15,504
    Does http://datatables.net/ref#iTabIndex cover what you need?

    Allan
  • I've done that and it worked for me.
  • gdwolgastgdwolgast
    Posts: 4
    My tables are created after the document is built so using that code won't work. Can you use iTabIndex when the table is created? In my case this would be after the document is already built. The table creation occurs on a button click event.
  • allanallan
    Posts: 15,504
    Can you use iTabIndex when the table is created?

    You can only use it when you call $(...).dataTable({ ... }); for the first time for a given table. If that isn't enough for you, then you can alter the attributes using standard jQuery calls with $(...).attr();

    Allan
  • gdwolgastgdwolgast
    Posts: 4
    That's a good idea. I'll give that a try.
This discussion has been closed.
← All Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Support

Get useful and friendly help straight from the source.

In this Discussion