I have a jquery toggling menu with password fields. By default, the submit button is disabled, and enabled on keyup events.
$(function(){
$("#submitProfile").attr("disabled","true");
$("#password_confirmation, #password, #current_password").keyup(function(){
$("#submitProfile").removeAttr("disabled");
});
});
But how can I keep the button disabled until all the fields are filled?