function first(a){
if (a == 'a'){
return false;
}
}
function second(){
return 'a';
}
$('.c').click(first).click(second);
How to send message to other chained events? Or stop others from one?
function first(a){
if (a == 'a'){
return false;
}
}
function second(){
return 'a';
}
$('.c').click(first).click(second);
How to send message to other chained events? Or stop others from one?
次のクリックの発生を停止するには、 stopImmediatePropagationメソッドを使用できます。
$("p").click(function(event){
event.stopImmediatePropagation();
});
$("p").click(function(event){
// This function won't be executed
});
コールバック間でメッセージを送信するには、外部変数を使用する以外の方法はわかりません。