Event handler multipli




La funzione on permette di associare piu' event handler allo stesso
elemento
Esempio:
$("li").on({
mouseenter: function(){
$(this).css("background-color", "lightblue");
},
mouseleave: function(){
$(this).css("background-color", "lightred");
},
click: function(){
$(this).css("background-color", "lightgreen");
}
});










( eventhandlermultipli.html )- by Paolo Puglisi - Modifica del 17/12/2023