该方法将编译生成一个 XPathExpression
,可以用来多次的执行.
语法
xpathExpr = document.createExpression(xpathText, namespaceURLMapper);
参数
- String
xpathText
(将要编译的Xpath表达式) - Function
namespaceURLMapper
(将一个命名空间前缀映射到一个命名空间URL上 (如果不需要,可以为null
))
该方法将编译生成一个 XPathExpression
,可以用来多次的执行.
xpathExpr = document.createExpression(xpathText, namespaceURLMapper);
xpathText
(将要编译的Xpath表达式)namespaceURLMapper
(将一个命名空间前缀映射到一个命名空间URL上 (如果不需要,可以为null
))Document
Document.activeElement
Document.alinkColor
Document.anchors
Document.applets
Document.async
Document.bgColor
Document.body
Document.characterSet
ParentNode.childElementCount
ParentNode.children
Document.compatMode
Document.contentType
Document.currentScript
Document.defaultView
Document.designMode
Document.dir
Document.doctype
Document.documentElement
Document.documentURI
Document.documentURIObject
Document.domain
Document.domConfig
Document.embeds
Document.fgColor
ParentNode.firstElementChild
Document.forms
Document.head
Document.height
Document.images
Document.implementation
Document.inputEncoding
ParentNode.lastElementChild
Document.lastModified
Document.lastStyleSheetSet
Document.linkColor
Document.links
Document.location
Document.mozFullScreen
Document.mozFullScreenElement
Document.mozFullScreenEnabled
Document.mozSyntheticDocument
GlobalEventHandlers.onabort
Document.onafterscriptexecute
Document.onbeforescriptexecute
GlobalEventHandlers.onblur
GlobalEventHandlers.onchange
GlobalEventHandlers.onclick
GlobalEventHandlers.onclose
GlobalEventHandlers.oncontextmenu
GlobalEventHandlers.ondblclick
GlobalEventHandlers.onerror
GlobalEventHandlers.onfocus
GlobalEventHandlers.oninput
GlobalEventHandlers.onkeydown
GlobalEventHandlers.onkeypress
GlobalEventHandlers.onkeyup
GlobalEventHandlers.onload
GlobalEventHandlers.onmousedown
GlobalEventHandlers.onmousemove
GlobalEventHandlers.onmouseout
GlobalEventHandlers.onmouseover
GlobalEventHandlers.onmouseup
Document.onoffline
Document.ononline
GlobalEventHandlers.onscroll
GlobalEventHandlers.onselect
GlobalEventHandlers.onsubmit
Document.origin
Document.plugins
Document.pointerLockElement
Document.popupNode
Document.preferredStyleSheetSet
Document.readyState
Document.referrer
Document.scripts
Document.selectedStyleSheetSet
Document.styleSheets
Document.styleSheetSets
Document.title
Document.tooltipNode
Document.URL
Document.vlinkColor
Document.width
Document.xmlEncoding
Document.xmlVersion
Document.adoptNode()
Document.caretPositionFromPoint()
Document.clear()
Document.close()
Document.createAttribute()
Document.createCDATASection()
Document.createComment()
Document.createDocumentFragment()
Document.createElement()
Document.createElementNS()
Document.createEntityReference()
Document.createEvent()
Document.createExpression()
Document.createNodeIterator()
Document.createNSResolver()
Document.createProcessingInstruction()
Document.createRange()
Document.createTextNode()
Document.createTouch()
Document.createTouchList()
Document.createTreeWalker()
Document.elementFromPoint()
Document.enableStyleSheetsForSet()
Document.evaluate()
Document.execCommand()
Document.exitPointerLock()
Document.getBoxObjectFor()
Document.getElementById()
Document.getElementsByClassName()
Document.getElementsByName()
Document.getElementsByTagName()
Document.getElementsByTagNameNS()
Document.getSelection()
Document.hasFocus()
Document.importNode()
Document.loadOverlay()
Document.mozCancelFullScreen()
Document.mozSetImageElement()
Document.open()
Document.queryCommandSupported()
Document.querySelector()
Document.querySelectorAll()
Document.registerElement()
Document.releaseCapture()
Document.write()
Document.writeln()