0
$("div").bind("click", function() {
    $("body").append("<p>click event</p>");
}).bind("click.plugin", function() {
    $("body").append("<p>click.plugin event</p>");
})

$("button").click(function() {
    $("div").trigger("click!");  
});

In book said that ! is to match all click methods which don't include in namespace. That means click the button only execute click event!

But this trigger doesn't work.

colorfulberry
  • 41
  • 1
  • 4

0 Answers0