Adding Custom Classes to a jQuery Dialog Button
If you need to add a custom class to a button in a jQuery dialog there's a property class</code> that you can specify to get your custom classes:
$('#customDialog').dialog(
{title : 'Custom Dialog Title',
buttons : [{text : 'Cancel',
click : function() {
$(this).dialog('close')
},
class : 'custom-class'
}]
}
);
<div id="customDialog">Some content</div>
Written by Rodrigo Martinez
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Jquery
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#