I'm using bootstrap in an PHP web application. I use the issues to generate a form, and include some checkbox's in the form, like this
//PHP Code To Generate the CheckBox
echo '';
Then, I manange the submit of the form manually, with ajax, and do something like this:
$.ajax({
type: 'post',
data: { $("#myCheckBox").val()},
url: 'someurl.php',
success: function () { alert('Something to do')}
});
The problem is when I recover the content of $_POST variables on PHP. The POST variable of the checkbox always contains 'on' as value.
Any help to get the value of this CheckBox using this way?
Thanks!.