如何使用缓解或addClass();
时间延迟?延迟添加类2秒悬停()
$("#date_1").hover(
function() {
$(this).addClass("door");
$(this).addClass("doorstatic", "slow"); // after 2seconds i want to add this class during the hover
},
function() {
$(this).removeClass("door");
$(this).removeClass("doorstatic"); // both classes are instantly removed when hover off
}
);
即使您选择在2秒钟之前移除鼠标(鼠标离开),悬停后(鼠标进入)2秒钟后,“门禁”级别可能会被添加。 – Stefan
但是我有几个..我有一个基本的日历和有一排箱子。用户可以使用鼠标和流过很多......有不止一个盒子旁边页EAC等.. – TheBlackBenzKid
尼斯!真像数据的使用'()'和''||操作者:) – Stefan