if checkbox checked jquery value 1

JavaScript
var checked = '0';  if($('#checkbox').prop('checked')){ checked = '1'; }
Source

Also in JavaScript: