Toggling between different tables

Toggling between different tables

marinamarina Posts: 19Questions: 0Answers: 0
edited December 2011 in General
I would like to have a drop down of table names and based on the users selection switch the table currently being displayed. Currently I have one table showing (using server-side processing) , I have the drop down graphically there however not quite sure how to hook it up with DataTables.

I need to somehow pass a variable to server_processing.php containing the new tables name. Not sure how or if possible to add the call below:

$(document).ready(function(){
$('#the_table').dataTable({
'bProcessing':true,
'bServerSide':true,
'sAjaxSource':'server_processing.php'
}).fnSetFilteringDelay();
});

Any help appreciated,
Marina

Replies

  • allanallan Posts: 63,535Questions: 1Answers: 10,475 Site admin
    Passing extra variables to the server-side processing script: http://datatables.net/release-datatables/examples/server_side/custom_vars.html (needs 1.8.2).

    Allan
  • marinamarina Posts: 19Questions: 0Answers: 0
    Thanks Allan!
This discussion has been closed.