Toggle disabled on input

by unequalsine

HTML

<input type="checkbox" id="checkbox"/>
<input disabled type="submit" id="item"/>

JavaScript

$('#checkbox').click(function() {
    if (this.checked) {
        $('#item').prop('disabled', false); // If checked enable item      
    } else {
        $('#item').prop('disabled', true); // If checked disable item                  
    }
});