Home > other >  jQuery DataTables - Remove search Label
jQuery DataTables - Remove search Label

Time:04-28

I am using jquery datatable and I want to remove search text label before input and i have no experience with jquery how to remove search label ? please help me thanks.

enter image description here

Jquery datatable

$(document).ready(function() {
  $("#userTable").dataTable({
    columnDefs: [{
        "defaultContent": "-",
        "targets": "_all"
    }]
  });

//custom format of Search boxes
$('[type=search]').each(function () {
    $(this).attr("placeholder", "Search...");
    $(this).before('<span ></span>');
});
});

CodePudding user response:

Try With this code:

$("#dataTable").DataTable({
    language : { search : "" },
});
  • Related