摘要: 创建节点:createElement();createTextNode()复制节点:cloneNode()插入节点:appendChild();insertBefore()删除节点:removeChild()替换节点:replaceChild()设置节点属性:setAttribute()查找节点:getAttribute();getElementById();getElementsByTagName();hasChildNodes节点的属性:nodeName;nodeType;nodeValue遍历节点树:childNodes;firstChild;lastChild;nextSibling; 阅读全文
posted @ 2013-12-14 16:04 11014p 阅读(172) 评论(0) 推荐(0)
摘要: 一、js常用方法1.document.write("");为输出语句2.JS中的注释为//3.传统的HTML文档顺序是:document->html->(head,body)4.一个浏览器窗口中的DOM顺序是:window->(navigator,screen,history,location,document)5.得到表单中元素的名称和值:document.getElementById("表单中元素的ID号").name(或value)6.一个小写转大写的JS:document.getElementById("output& 阅读全文
posted @ 2013-12-14 16:03 11014p 阅读(228) 评论(0) 推荐(0)