I am playing with Bootstrap\'s stateful buttons - specifically with Loading state, but still can\'t find the right set up to get it working. I have a simple for
You need to explicitly set that the button is in the loading state. Something like this:
// Set up the buttons
$(button).button();
$(button).click(function() {
$(this).button('loading');
// Then whatever you actually want to do i.e. submit form
// After that has finished, reset the button state using
// $(this).button('reset');
}
I've created a working JSFiddle example.