DataTables获取表单输入框数据

$(document).ready(function() {
    var table = $('#example').DataTable();
    $('button').click(function() {
        var data = table.$('input, select').serialize();
        alert("The following data would have been submitted to the server: \n\n" + data.substr(0, 120) + '...');
        return false;
    });
});

  

posted on 2015-06-27 20:20  Admin_csq  阅读(831)  评论(0编辑  收藏  举报