JavaScript is an object-oriented computer language, so it looks a little different than traditional procedural languages, such as C and Pascal. For starters, programmers describe data and procedures in terms of objects, methods, and properties--not variables, routines, and statements. JavaScript programming uses a number of specialized terms:

client: in terms of Web-based applications, a client is the computer running a Web browser. Web pages are loaded from Web servers to Web clients, where they're displayed.

event handler: a special attribute that associates an object with an event. For instance, you can associate a button with a mouse click by using the onClick event handler. You can find a list of event handlers at Netscape's JavaScript reference page.

function: a named set of JavaScript statements interpreted all at once by calling the function name. JavaScript has several built-in functions, but you can extend the list by writing your own.

instance: one particular incarnation of an object. For example, while president may be an object, Bill Clinton is an instance of president. Similarly, a Web page button is an object, but myCalculateButton is an instance.

method: an action that a particular object can perform. Methods are implemented just like functions, but they're always associated with a particular object. Think of methods as verbs. You'll find a list of methods at Netscape's JavaScript reference page.

object model: a group of objects that work together for a common purpose. The JavaScript object model comprises all the elements that make up a Web page.

object: any thing, idea, or concept is an object. Object-based languages like JavaScript make it easy to model and work with real-world objects, such as Web pages and Web-page elements. Objects are typically nouns. For example, window, document, and image are all JavaScript objects.

property: a one-word attribute that describes an object. For example, length, name, and target are all JavaScript properties. In JavaScript, an object's properties are defined by using the object's name, a period, and the property name. Furthermore, an object can contain other objects. For instance, a check box named pepperoni on a pizza order form might have its value referenced like this: document.orderform.pepperoni.value. Check out Netscape's JavaScript reference page for a list of available properties.

Review:

Event Handler  Attributes of HTML tags embedded in documents. The attribute assigns a JavaScript command or function to execute when the event happens.

Function  A user-defined or built-in set of statements that perform a task. It can also return a value when used with the return statement.

Hierarchy  Navigator objects exist in a set relation to each other that reflects the structure of an HTML page. This is referred to as instance hierarchy because it only works with specific instances of objects, rather than general classes. The window object is the parent of all other Navigator objects. Underneath window, location, history, and document all share precedence. Document includes forms, links, and anchors.

Each object is a descendant of the higher object. A form called orderForm is an object, but is also a property of document. As such, it is referred to as document.orderForm.

Java  An object-oriented, platform-independent programming language developed by Sun Microsystems and used to add additional functionality to Web pages. Programming in Java requires a Java Development Kit with compiler and core classes. Although Java started out as a language intended for writing Web applets, more and more stand-alone Java applications are being created.

JavaScript  A scripting language developed by Netscape for HTML documents. Scripts are performed after specific user-triggered events. Creating JavaScript Web documents requires a text editor and compatible browser.

Literal  An absolute value not assigned to a variable. Examples include 1, 3.1415927, "Bob", true.

Method  A function assigned to an object. For example, bigString.toUpperCase() returns an uppercase version of the string contained in bigString.

Object  A construct with properties that are JavaScript variables or other objects. Functions associated with an object are known as the object's methods. You access the properties of an object with a simple notation:

objectName.propertyName

Both object and property names are case sensitive.

Operator  Performs a function on one or more operands or variables. Operators are divided into two classes: binary and unary. Binary operators need two operands, and unary operands can operate on a single operand. For example, addition is a binary operand:

sum = 1 + 1

Unary operands are often used to update counters. The following example increases the variable by 1:

counter++

Property  Used to describe an object. A property is defined by assigning it a value. There are several properties in JavaScript that contain constants: values that never change.

Script  One or more JavaScript commands enclosed with a <script> tag.