11.12.2012 Views

JavaScript 2.0-The Complete Reference, Second ... - freecodingtutorial

JavaScript 2.0-The Complete Reference, Second ... - freecodingtutorial

JavaScript 2.0-The Complete Reference, Second ... - freecodingtutorial

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

insertAdjacentElement() for the meaning of this parameter. <strong>The</strong> text is parsed and<br />

added to the document tree. (IE5+)<br />

insertAdjacentText(where, text) Inserts the text given in string text adjacent to the<br />

current element according to the string where. See table under<br />

insertAdjacentElement() for the meaning of this parameter. <strong>The</strong> text is not parsed as<br />

HTML. (IE5+)<br />

insertBefore(newChild, refChild) Inserts node newChild in front of refChild in the<br />

childNodes[] list of refChild's parent node. (IE5+, MOZ/N6+, DOM1 Core)<br />

isSupported(feature [, version]) Returns a Boolean indicating whether feature and<br />

version given in the argument strings are supported. (MOZ/N6+, DOM2 Core)<br />

mergeAttributes(source [, preserve]) Merges all attributes, styles, and event<br />

handlers from the element node source into the current element. (IE5+)<br />

normalize() Recursively merges adjacent text nodes in the sub-tree rooted at this<br />

element. (IE6+, MOZ/N6+, DOM1 Core)<br />

releaseCapture() Disables universal mouse event capturing at that object. (IE5+)<br />

removeAttribute(name) Removes attribute corresponding to string name from the<br />

node. (IE4+, MOZ/N6+, DOM1 Core)<br />

removeAttributeNode(attribute) Removes the attribute node given by node attribute<br />

and returns the removed node. (IE6+, MOZ/N6+, DOM1 Core)<br />

removeBehavior(id) Removes the DHTML Behavior associated with id (previously<br />

returned by attachBehavior()) from the element. (IE4+)<br />

removeChild(oldChild) Removes oldChild from the node‘s children and returns a<br />

reference to the removed node. (IE5+, MOZ/N6+, DOM1 Core)<br />

removeEventListener(whichEvent, handler, direction) Removes function handler as<br />

a handler for the event given in the string whichEvent (for example, "click") for the<br />

phase given by the Boolean direction. (MOZ/N6+, DOM2)<br />

removeExpression(propertyName) Removes dynamic property expression for the<br />

property given in the string propertyName. (IE5+)<br />

replaceAdjacentText(where, text) Replaces the text at position where relative to the<br />

current node with the text (non-HTML) string text (IE5+). Possible values for where<br />

include<br />

Value of<br />

where<br />

Effect<br />

"beforeBegin" Replaces text immediately before the object (back to but not including first<br />

tag or end tag encountered).<br />

"afterBegin" Replaces text at the start of the object but before all other enclosed content<br />

(up to but not including first opening tag).<br />

"beforeEnd" Replaces text immediately before the end of the object, after all other<br />

content (back to but not including last tag or closing tag).<br />

"afterEnd" Replaces text immediately after the element‘s closing tag (up to but not<br />

including the next tag).<br />

replaceChild(newChild, oldChild) Replaces the node‘s child node oldChild with node<br />

newChild. (IE5+, MOZ/N6+, DOM1 Core)<br />

replaceNode(newNode) Replaces the current node with newNode. (IE5+)<br />

scrollIntoView([alignToTop]) Causes the object to be immediately scrolled into the<br />

viewable area of the window. If alignToTop is true or omitted, the top of the object is<br />

aligned with the top of the window (if possible). Otherwise, if alignToTop is false, the<br />

object is scrolled so that the bottom of the object is aligned with the bottom of the<br />

viewable window. (IE4+)<br />

setActive() Sets the object as the active object without giving it focus. (IE5.5+)<br />

setAttribute(name, value) Sets a new attribute for the node with name and value<br />

given by the string arguments. (IE4+, MOZ/N6+, DOM1 Core)<br />

setAttributeNode(newAttr) Adds the attribute node newAttr (replacing and returning<br />

any attribute node with the same name). (IE6+, MOZ/N6+, DOM1 Core)<br />

setCapture([containerCapture]) Causes all mouse events occurring in the document<br />

to be sent to this object. (IE5+)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!