JavaScript: A History The JavaScript language was created by Netscape engineer Brendan Elch in the 1990s. Originally called Mocha, it made its first appearance in the third beta version of Netscape Navigator 2.0 in 1995. Later that year, Netscape arranged with Sun Microsystems, owner of the Java language, to rename the language to JavaScript (after calling it LiveScript for some time). This has led to confusion ever since, because JavaScript and Java do not share any similarities at all, with the exception that they're both C-style languages. JavaScript enabled HTML pages to be really dynamicincluding instant form data validation, graphical effects, user interaction, and much more. In a time when bandwidth was limited (most users had slow dial-up lines) and server roundtrips costly in time, JavaScript gave web developers a tool to make their sites more interactive. When JavaScript took off, Microsoft added scripting capabilities to its own browser, Internet Explorer, as well. For copyright reasons, however, they named their version of the language JScript, but it was a JavaScript work-alike. In 1997, the browser war between Netscape Navigator (still the market leader) and Internet Explorer (soon to become the market leader) reached a climax. Netscape 4 was released in June, introducing JavaScript Version 1.2 with new capabilities. In the same month, the ECMA standard ECMA-262 was announced, which formalized the scripting language (see http://www.ecma-international.org/publications/standards/Ecma-262.htm). JavaScript, therefore, is an implementation of ECMA-262 or ECMAScript. In October of the same year, Internet Explorer 4 was released, supporting only JavaScript 1.1 (and VBScript, a scripting language based on Visual Basic; we do not address VBScript here because it runs only in Internet Explorer and is therefore not relevant for browser-agnostic client scripting). At that point, the browsers were quite incompatible, especially when it came to implementing effects like positioning and moving elements. The mix of technologies used to achieve these kinds of effects has been dubbed Dynamic HTML (DHTML). Despite popular belief, DHTML is not a standard at all, but a fabricated term, just like Ajax. Then, things changed dramatically. Netscape scrapped an almost-ready Version 5 of its browser and decided to rewrite it from scratch. This led to an immature Version 6 of Netscape, based on the new open source Mozilla project and the Gecko rendering engine. The delays and the quality issues of the browser cost Netscape their market share, and Internet Explorer took the lead. However, development of Internet Explorer stalled with Version 6, and the Firefox browser (also based on Mozilla but only the browser, not additional features such as mail or news reader) started reclaiming some of Internet Explorer's market share. Internet Explorer 7 is currently available as a beta, so the race is on again. From a JavaScript point of view, not very much has changed in recent years. After the death of Netscape 4, the major browsers (which include Internet Explorer and Mozilla, as well as Safari, Konqueror, and Opera) are relatively compatible to each other (regarding their JavaScript support), although some differences and issues remain. The lack of innovation in browsers also held back widespread use of Java- Script, and books on the topic received very few updates in the last couple of years. However, this all changed with the invention of the term Ajax. Although the technology behind Ajax has existed since 1998, it only recently moved into mainstream web programming. Chapter 3 covers this in more detail. |