You don't have to be a geek, baby, to write JavaScript my way

Remember back when java referred to coffee? For computer geeks, Sun Microsystems Inc.'s
Java now is the hottest programming language around. The rest of us geek-wannabes probably
won't ever master its full complexities, but many of us will learn a scripting language
subset known as JavaScript.

Embedded JavaScript makes your Hypertext Markup Language Web pages more versatile and
functional. It's a client-side scripting technology, born as LiveScript at Netscape
Communications Corp.

JavaScript is supported by Netscape Communications Corp.'s Navigator 2.0 and higher
versions of the browser--though not all those versions fully support Java. Go figure.
JavaScript also will be fully supported by Microsoft Corp.'s Internet Explorer 3.0 browser
and later versions.

In addition, Explorer 3.0 will support the client-side scripting language Visual Basic
Script, a subset of Visual Basic for Applications. But Netscape Navigator, at least as of
this writing, doesn't support VBScript. Confused yet?

If you've been doing HTML, you should be able to pick up client-side scripting with
JavaScript or VB Script very easily. There are a lot of Internet resources for client-side
scripting and a lot of how-to books in your bookstore or soon to come. See Netscape's
World Wide Web site at
  for JavaScript, or see Microsoft's site at
  for VBScript and JavaScript.

Many other Web sites contain extensive information about JavaScript, including
public-domain scripts you can borrow. For example, check out  The concepts are the same,
whichever scripting language you use. I believe all browsers should support them both.

Here's a simple example of how to place a button on a Web page and have it pop up an
alert when clicked insert html code here.

To try it out, simply type into a text editor, save as testme.html, then open in
Netscape Navigator 2.0 or higher or Internet Explorer 3.0.

To put this script into your HTML, use the < /script > HTML tag; the language can
be either JavaScript or VBScript.

This is an example of a predefined function--the pushbutton--in JavaScript. The
function is loaded into memory and declared in the header as the HTML page loads. It then
waits for the user to click on the normal HTML < form >< /form > tag.

Stay Connected

Sign up for our newsletter.

I agree to this site's Privacy Policy.