針對滑鼠移入移出和點選事件衝突的解決
阿新 • • 發佈:2021-01-06
$('.export').hover(function(){
$(this).addClass("active");
}).mouseout(function(){
if($(this).html() != _nowText){
$(this).removeClass("active");
}
});
var _nowText ; $(".export_list .export").click(function () { $(this).addClass('active').siblings('.export').removeClass('active'); _nowText = $(this).text(); })