rwxkla
Last Updated: February 25, 2016
·
1.414K
· ihcsim

Disable jquery-ui Buttons

To disable a jquery-ui button created via $.button use either

$( ".selector" ).button({ disabled: true });

Or

$( ".selector" ).button( "option", "disabled", true );

As

$( ".selector" ).attr("disabled", "disabled");

Won't work.

Reference: http://api.jqueryui.com/button/#option-disabled