js 阻止冒泡事件需要添加的代码

e  =  e || window.event;
if(document.all){
    e.stopPropagation();
}else{
    window.event.cancelBubble = true; 
}

你可能感兴趣的:(js 阻止冒泡事件需要添加的代码)