Jiving with Javascript
By Kevin M. Savetz
Once upon a time, all Web pages were static. CGI programs started to change that by allowing powerful searches of Web pages, sites that modified themselves based on the time of day or the phase of the moon, and even interactive games. Java, a powerful programming language, is bringing a whole new level of interactivity to the Web. Somewhere in the middle is JavaScript, a new language that's simple enough for beginning programmers to learn, but powerful enough to interact with Web pages and Java applets in ways never before possible with any language.
Static Web pages are now a dying breed. Although not obsolete yet, it may be one day soon that a Web page that doesn't do anything just won't get a second glance. That's why JavaScript is worth a careful look, especially if your first look at Java scared you away.
JavaScript is a fledgling language. As I write this, JavaScript isn't even complete. The technical specifications of the language have been agreed upon, but no Web browsers completely support JavaScript. (JavaScript 3.0, which should incorporate the functions that are currently lacking, is due out in June, give or take a month; no firm date had been set at press time.) But that doesn't mean that no one is using it; bleeding-edge Web hackers have been experimenting with the crippled JavaScript for months, and many are impressed with what they see.
What is JavaScript?
Java and JavaScript are distinct languages, with different purposes and features. JavaScript was designed to provide an easy way for Web authors to create interactive Web pages. Java is a programming language that is used to create stand-alone applications called applets. Unlike Java, which is meant for experienced programmers with an understanding of C++, JavaScript is a simpler "scripting" language (as are dBASE and AppleScript) aimed at those with less programming experience.
Both are powerful languages, but each offers distinct advantages. According to Andy Augustine, vice president of technology for Frequency Graphics, a Web development and hosting service provider, "JavaScript is aimed at the people who don't have C++ experience, people who don't have much experience with CGI, but want to create some sort of interactive Web page."
[Move on the Part II]
Reprinted from Web Developer® magazine, Vol. 2 No. 2 Spring 1996 (c) 1996 internet.com Corporation. All rights reserved.