What Is JavaScript?
JavaScript is an interpreted(rather than compiled) object-oriented programming language
that has been developed for use alongside other Web tools. JavaScript does not operate as
a standalone language. It is designed to work together with HTML for creating interactive
Web pages. It is not the same as Java, which is a compiled object-oriented language.
JavaScript is used to write client side applications, which means that JavaScript code
is sent to a user’s computer when a Web page is loaded. The code is then executed, basi-cally line by line, by a JavaScript interpreter included as part of the user’s (client’s) Web
browser. This arrangement minimizes security issues that can arise when a client computer
interacts with the computer that sent the page. It also makes it easy to package an entire
problem, with its own user interface and solution, self-contained within a single document.
But the inability to interact dynamically with information stored on a serverimposes limi-tations on the kinds of tasks that JavaScript can accomplish.
It is commonplace to refer to any set of written computer instructions as a “program.”
However, this term is more rigorously applied to a separate entity that can be executed on its
own. Because JavaScript is interpreted rather than compiled, a separately executable entity is
never created. Instead, JavaScript code statements are interpreted and executed one at a time,
essentially “on the fly.” Although this may seem inefficient, there is rarely any discernible
time lag associated with executing JavaScript commands on modern computers.
JavaScript is one of a class of scripting languages whose purpose is to access and mod-ify components of an existing information interface. (Microsoft’s VBScript is another
scripting language.) In this case, the interface is an HTML document. As soon as HTML
documents on the Web evolved from one-way delivery systems for displaying fixed con-tent, something like JavaScript immediately became necessary. One of its first applications
arose from the need to check values entered by users into the fields of HTML forms that
can be sent back to the originator. (Forms are discussed in a later chapter.) JavaScript can
be used to compare input values against an expected range or set of values and to generate
appropriate messages and other actions based on those comparisons.
JavaScript has evolved into a complete programming language with extensive capabili-ties for manipulating text and handling mathematical operations, useful for a wide range of
computing problems. Possible applications include many self-contained scientific and
engineering calculations. As noted earlier, JavaScript is restricted to problems that do not
need to access external data sources, regardless of whether those sources reside on a local
computer or on a remote server.
JavaScript is an interpreted(rather than compiled) object-oriented programming language
that has been developed for use alongside other Web tools. JavaScript does not operate as
a standalone language. It is designed to work together with HTML for creating interactive
Web pages. It is not the same as Java, which is a compiled object-oriented language.
JavaScript is used to write client side applications, which means that JavaScript code
is sent to a user’s computer when a Web page is loaded. The code is then executed, basi-cally line by line, by a JavaScript interpreter included as part of the user’s (client’s) Web
browser. This arrangement minimizes security issues that can arise when a client computer
interacts with the computer that sent the page. It also makes it easy to package an entire
problem, with its own user interface and solution, self-contained within a single document.
But the inability to interact dynamically with information stored on a serverimposes limi-tations on the kinds of tasks that JavaScript can accomplish.
It is commonplace to refer to any set of written computer instructions as a “program.”
However, this term is more rigorously applied to a separate entity that can be executed on its
own. Because JavaScript is interpreted rather than compiled, a separately executable entity is
never created. Instead, JavaScript code statements are interpreted and executed one at a time,
essentially “on the fly.” Although this may seem inefficient, there is rarely any discernible
time lag associated with executing JavaScript commands on modern computers.
JavaScript is one of a class of scripting languages whose purpose is to access and mod-ify components of an existing information interface. (Microsoft’s VBScript is another
scripting language.) In this case, the interface is an HTML document. As soon as HTML
documents on the Web evolved from one-way delivery systems for displaying fixed con-tent, something like JavaScript immediately became necessary. One of its first applications
arose from the need to check values entered by users into the fields of HTML forms that
can be sent back to the originator. (Forms are discussed in a later chapter.) JavaScript can
be used to compare input values against an expected range or set of values and to generate
appropriate messages and other actions based on those comparisons.
JavaScript has evolved into a complete programming language with extensive capabili-ties for manipulating text and handling mathematical operations, useful for a wide range of
computing problems. Possible applications include many self-contained scientific and
engineering calculations. As noted earlier, JavaScript is restricted to problems that do not
need to access external data sources, regardless of whether those sources reside on a local
computer or on a remote server.
No comments:
Post a Comment