To place a button for searching in the table .

To place a button for searching in the table .

alabalab Posts: 2Questions: 0Answers: 0
edited November 2011 in DataTables 1.8
I have a typical requirement when searching data dynamically in jQuery datatable.

Is it possible to bind the search field with a button? What I mean is I don't want to redraw the table based on each character input. I wish to first enter the data in the field and then search the table by clicking the button.(to make it easier for people who are not familiar with.)

I have temporarily disabled the input of the search, I want to begin the search when button is pressed after the newly provided for the search.

Please indicate if you know how to solve it if you.

If anyone of you has done something similar I'd be much obliged if you could assist.

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,470 Site admin
    There is a plug-in which does filtering on return key here: http://datatables.net/plug-ins/api#fnFilterOnReturn . I know its not exactly what you asked for, but it will give you an example of how modifying the search box can be done.

    An alternative is just to create your text input and button normally and bind a call to fnFilter on to the button.

    Allan
  • alabalab Posts: 2Questions: 0Answers: 0
    Thank you from the bottom of my heart.

    I really appreciate to your advice.

    Thank a lot , Mr.Allan.
This discussion has been closed.