I made checkbox the data from database and still work, when I click multiple checkbox, the count of data clicked is matches
the problem when I sending data to filter.php with method post
the count of data received is not matches event click jquery
$(document).ready(function() {
$('#t_pendaftar').DataTable();
$('#filter').click(function () {
var data = { 'venue[]' : []};
var arr = $('.treas:checked').map(function () {
data['venue[]'].push($(this).val());
}).get();
console.log(data);
$.post("filter.php",{data : data});
});
});
filter.php
<?php var_dump($_POST['data']); if(!empty($_POST['data'])) {
foreach($_POST['data'] as $check) {
print_r($check);
} } ?>
thank you for attention
Aucun commentaire:
Enregistrer un commentaire