I am binding custom event on buttons to apply Jquery ui button plugin like :
$(document).ready(function() {
$(".uibutton").live("CustomEvent", function() { $(this).button(); });
$(".uibutton").trigger("CustomEvent");
});
<input type="button" class="uibutton" >
Now this works good for the button which are present in the MarkUP but the buttons which are created dynamically with class uibutton, this is not working. Can anybody please tell me why ?
$(“.uibutton).trigger(“CustomEvent”);
There is missing closure quotation.
it should be like this:
$(“.uibutton”).trigger(“CustomEvent”);
try it.