JavaScript API Reference

The rest of this chapter contains a quick-reference for the core and client-side JavaScript APIs. It documents the complete core JavaScript API, covers the legacy (Level 0) DOM API, and presents a simplified view of the W3C Level 2 DOM API. Portions of that API not relevant to JavaScript programmers working with HTML documents have been omitted. The upper-right corner of the title block for each reference entry contains information that states whether a feature is part of the core or client-side API, and further indicates which version of JavaScript, which browsers, or which version of the DOM introduced the feature.

Because JavaScript is a loosely-typed language, there is not an official set of class names for the classes and objects of the JavaScript API, and they sometimes appear under different names in different references. The following table summarizes the reference entries that follow, and allows you to quickly scan for the class or object you are interested in.

Anchor

A named position in a document

Applet

A Java applet

Arguments

The arguments of a function

Array

Array creation and manipulation

Attr

An attribute of a document element

Boolean

A wrapper object for boolean values

Comment

An HTML comment

DOMException

Signals DOM errors

DOMImplementation

Creates documents, checks DOM features

Date

Manipulates dates and times

Document

An HTML document

DocumentFragment

Nodes to be manipulated together

Element

An HTML tag in a document ...

Get Webmaster in a Nutshell, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.