Customize search input/ filter input

Customize search input/ filter input

jerminator1980jerminator1980 Posts: 2Questions: 0Answers: 0
edited April 2012 in General
Hi,
I'm trying to customize Datatables such that I can put the filter bar at the top of the page, and below it have a series of other inputs that will, filter the columns.
I found the sDom functionality but that only seems to allow me to change the ordering and styling of html elements around the table.

Is it possible to do this? Or am I out to lunch... or does no one understand what the heck i'm talking about. Can some one point me in the right direction...

Much thanks is appreciated for your help.

Jer

[code]





test




Barcode
ID




Loading data from server




Barcode
ID










[/code]

Replies

  • allanallan Posts: 63,810Questions: 1Answers: 10,516 Site admin
    sDom only allows DOM positional control of elements inside the DataTables wrapper element. However, it is trivial to bind an event listener to a text input element that you've put anywhere on the page, and have it call fnFilter on the table when keyup is fired (or whatever). In this way you can use any input control you want to filter the table.

    Allan
  • jerminator1980jerminator1980 Posts: 2Questions: 0Answers: 0
    Awesome, thanks for your help Allan.
This discussion has been closed.