Java Reference
In-Depth Information
Other Statements
The following table lists other JavaScript statements and when they were introduced.
Statement
Introduced
Description
comment
JavaScript 1.0
Notes that are ignored by the script engine and that can be used
to explain the code. There are two types of comments: single-line
and multi-line.
// single line comment
/* multi
line
comment */
Top-Level Properties and Functions
These are core properties and functions, which are not associated with any lower-level object, although
in the terminology used by ECMAScript and by Jscript, they are described as properties and methods of
the global object.
The top-level properties were introduced in JavaScript 1.3, but in previous versions, Infinity and NaN
existed as properties of the Number object.
Top-Level Properties
Property
Introduced
Description
Infinity
JavaScript 1.3
Returns infi nity.
NaN
JavaScript 1.3
Returns a value that is not a number.
undefined
JavaScript 1.3
Indicates that a value has not been assigned to a variable.
Top-Level Functions
Function
Introduced
Description
decodeURI()
JavaScript 1.5
Used to decode a URI encoded with
encodeURI() .
decodeURIcomponent()
JavaScript 1.5
Used to decode a URI encoded with
encodeURIComponent().
encodeURI()
JavaScript 1.5
Used to compose a new version of a complete
URI, replacing each instance of certain charac-
ters. It is based on the UTF-8 encoding of the
characters.
Search WWH ::




Custom Search