时间:2021-07-01 10:21:17 帮助过:8人阅读
文本教你用on方法,模拟hover方法。
代码如下:
$(obj).on("mouseover mouseout",function(event){
if(event.type == "mouseover"){
//鼠标悬浮
}else if(event.type == "mouseout"){
//鼠标离开
}
})
赶紧去以上就是JQuery使用on方法如何绑定hover事件的代码案例的详细内容,更多请关注Gxl网其它相关文章!