jquery show if checkbox checked code example
Example 1: if checkbox checked jquery value 1
var checked = '0'; if($('#checkbox').prop('checked')){ checked = '1'; }
Example 2: how to check input is selected or not
$('#' + id).is(":checked")
var checked = '0'; if($('#checkbox').prop('checked')){ checked = '1'; }
$('#' + id).is(":checked")