I\'m new to jquery and am facing now a weird problem. I succeeded to narrow it down to the fact that a mouseenter event is called twice: once for the containing div (this was my
i think that the second one does'nt work because the html is different. If you use the same html you don't need stopPropagation
or return false
at all. Look at the fiddle: http://jsfiddle.net/aC3TG/1/
$(function (){
$(".testDiv").hover(
function(e) /* IN */ {
$(this).data("htmlBackup", $(this).html());
$(this).html("TEST 123");
}, function(e) /* OUT */ {
$(this).html($(this).data("htmlBackup"));
});
});