search data inside data table after click button

search data inside data table after click button

kloxklox Posts: 4Questions: 0Answers: 0
edited June 2010 in General
hi all..
i have 3 textfield and 1 show button..i want after i have been type some string inside that then click the button..rhe datatable can show what i'm looking for...this is my first code:
"[code]
$(document).ready(function() {
var oTable;
$("#showdata").click(function(event){
oTable = $("#datalist").dataTable({
"bRetrieve" : true,
"bServerSide": true,
"bProcessing": true,
"sAjaxSource": 'showlist.php',
"fnServerData": function (sSource,aoData,fnCallback){
aoData.push({"name":"line","value":$("#showline").val()});
aoData.push({"name":"model","value":$("#showmodel").val()});
aoData.push({"name":"NIK","value":$("#showNIK").val()});

$.ajax({
"dataType":'json',
"type":'POST',
"url":sSource,
"data":aoData,
"success":function(json){
fnCallback(json);
}
});
},


"aaSorting" : [[1,"desc"]],
"aoColumns" : [
/*Line*/ null,
/*Model*/ null,
/*NIK*/ null
]
});
[/code]"
This discussion has been closed.