addevent

function addEvent(a, b, c, d) {
a.addEventListener ? a.addEventListener(b, c, d) : a.attachEvent("on" + b, c)
}

function removeEvent(a, b, c, d) {
a.removeEventListener ? a.removeEventListener(b, c, d) : a.detachEvent("on" + b, c)
}

posted on 2013-09-11 19:39  rainbow661314  阅读(136)  评论(0编辑  收藏  举报