HTML and CSS Reference
In-Depth Information
Appendix G
JavaScript Quick
JavaScript Introduction
Webster's dictionary defines script in several ways: first, as a style of handwriting or font style,
such as cursive; second, as a document; and third, as text for stage, film, or a radio or television
show. A stage, movie, or television script also contains stage directions for actors. Computers,
however, also use scripts, which are a set of instructions used by a program to perform a specific
task or set of tasks. A scripting language follows a set of rules and has its own syntax. Scripting
languages generally need to be interpreted by the program or utility using the script.
Scripting languages like JavaScript extend the power of HTML and allow Web
pages to be interactive. Whereas HTML tells your browser how to display text and
images, set up lists and option buttons, and establish hyperlinks, JavaScript brings Web
pages to life by adding dynamic content and interactive elements. Using JavaScript, a Web
page developer can add features such as:
Animation and dynamic images
Scrolling messages
Pop-up windows
Dynamic messages
Data validation
JavaScript is a product resulting from a joint venture between Sun Microsystems and
Netscape. Netscape developed a script language called LiveScript, and Sun Microsystems
was trying to simplify its Java programming language. The cooperation of those two efforts
brought about JavaScript. The first JavaScript standards were created and developed by
the European Computer Manufacturers Association (ECMA) with edition 1 in 1997. The
current edition of ECMAScript is edition 5, which was finalized in December of 2009.
JavaScript version 1.5 was based on ECMAScript edition 3. Disagreement among
members, who include Yahoo!, Microsoft, Mozilla, and Google has led to the development
of JavaScript extensions beyond version 1.5 based on individual browser engines. The
Mozilla developer Web site lists JavaScript at version 1.8.5. The versions beyond 1.5 are
browser specific, and contain objects, properties, and methods specific to that browser and
browser version.
The following reference guide applies to the JavaScript model version 1.5, which
is still in effect for all cross-browser applications. Later versions of JavaScript are
browser-specific and are not detailed in this appendix. For more detailed information
about JavaScript, see the Mozilla Developer Network Web site at
en/JavaScript. For the complete ECMA standards documentation, you can download the
PDF file at
Search WWH ::

Custom Search