摘要: return false 阅读全文
posted @ 2015-05-10 22:53 hello,w 阅读(108) 评论(0) 推荐(0) 编辑
摘要: document.onkeydown=function(ev){ console.log(ev); //KeyboardEvent} 阅读全文
posted @ 2015-05-10 22:39 hello,w 阅读(108) 评论(0) 推荐(0) 编辑
摘要: scrollTop: var sccrollTop=document.documentElement.scrollTop||document.body.scrollTop(前者ie、ff 后者chrome) 阅读全文
posted @ 2015-05-10 17:17 hello,w 阅读(86) 评论(0) 推荐(0) 编辑
摘要: 事件对象:IE下:就叫 event对象ff,chrome:传到事件处理函的那个参数名字(随便起)event对象:根据事件类型有具体的事件对象,比如mouseEvent keyboardEvent等,这些对象有各自的属性,如clientX keyCode等如:ie下document.body.oncl... 阅读全文
posted @ 2015-05-10 17:11 hello,w 阅读(325) 评论(0) 推荐(0) 编辑
摘要: 预备知识:childNodes:返回一个元素的子节点document:一个最顶层的虚拟节点:他有两个子节点: Document 这是body 以上可以看出 document html bo... 阅读全文
posted @ 2015-05-10 14:29 hello,w 阅读(279) 评论(0) 推荐(0) 编辑