Newsletter "Behind the Scenes" Newsletter

November 2013The monthly newsletter by Felgall Pty Ltd

My Word

JScript is Dead

In early web browsers there was not even the concept of a scripting language. Early web browsers were designed to display static web pages and that was it. None of the earliest browsers even thought of introducing such a thing - perhaps that's why none of those browsers survived once a browser with a scripting language was released.

The very first browser to support a scripting language was Netscape 2. By that time Netscape dominated the browser market and the vast range of earlier browsers were disappearing rapidly. Netscape were originally going to call their scripting language livescript but another programming language was big in the news at that time - Java. So to try to cash in on the Java name even though their scripting language had nothing in common with Java, Netscape decided to call their scripting language JavaScript.

Now JavaScript was a proprietary language that at that time belonged to Netscape. No one else could incorporate JavaScript into their browser. This by itself gave Netscape a huge edge over the competition and probably helped it to obtain a dominance in the browser market not seen again until ten years later with Internet Explorer.

Microsoft had obtained a copy of the first browser written by the programmers who created Netscape back in their university days - a browser originally called Mosaic and later after the university sold it Spyglass Mosaic. This had been a popular browser prior to the launch of Netscape which had deliberately set out to have the same guys who wrote mosaic write a mosaic killer - something they achieved with Netscape. So when Microsoft finally entered the browser market with Internet Explorer their browser was a modified version of Spyglass Mosaic. As this was basically a browser that had already been made obsolete by the release of Netscape, Microsoft didn't do too well with their browser at first but they started working on improvements to try to catch up with Netscape.

When JavaScript was released in Netscape 2, Microsoft had to produce an equivalent for Internet Explorer or see their browser go the way of so many others that were dying out at that time. Their response was to produce their own scripting language which they called JScript in Internet Explorer 3. Now JScript was at least a bit similar to JavaScript but it used different commands to perform some of the functionality. Since both languages had feature sensing built in it was possible to write a hybrid of JavaScript and JScript that would run as whichever language the browser supported. All your script had to do is to test whether the browser supported the JavaScript or JScript version of the command and use whichever one the browser recognised to perform that processing.

The browser wars hit their peak with Netscape 4 and Internet Explorer 4 with both browsers providing all the same functionality but using different code to do it. Some web sites even produced two versions of each page as the only way to provide full functionality to users of both browsers. Microsoft was gradually leveraging their way to greater market share in the browser market - something they'd considered to be entirely unimportant until after Netscape was first released.

Microsoft gained their biggest advantage when the people at Netscape decided that the code behind Netscape had been patched too many times and that a complete rewrite was needed (you can imagine how much worse the code behind Internet Explorer must have been since it was based on code that had already been rewritten from scratch in creating Netscape - however this didn't bother Microsoft.

With no new version of Netscape to compete with Microsoft had a clear path to dominance with Internet Explorer 5 and 6 which were also somewhat innovative in implementing proposed changes to the standards before the standards were finalised. Yes there were standards for the web tby that point which browsers were effectively being forced to consider as no one wanted to risk being the loser in another battle between incompatible browsers as had happened with Netscape 4 and Internet Explorer 4. In fact IE5 implemented some of the new standards so early that the concept had changed by the time the standard was completed and so IE5 implemented a variant that had subsequently been changed. The only way that Microsoft could handle pages written for both the IE5 version implemented before the final standard and the final version of the standard was to find a way to provide a switch to Internet Explorer 6 telling the browser which of the two ways to use. This was the origin of quirks mode and the use of the doctype as a switch.

With Internet Explorer 6 dominating the market, Microsoft stopped development. Almost everyone was using their browser because it had the best support for the standards and it had JScript as a scripting language.

At that point JavaScript might have died out except that Netscape decided to give up their proprietary rights to the language and handed it over to the international standards body ECMA. This now meant that all browsers could incorporate the same version of JavaScript. Since Microsoft had stopped development with IE6 an opportunity arose for other browsers to be developed that followed the standards even more closely than IE6 did and these new browsers all implemented JavaScript because JScript was still owned by Microsoft.

Microsoft's failure to continue developing Internet Explorer eventually meant that what had at one time had been the most standards compliant browser was now the least standards compliant. There were also more and more security holes in IE6 being identified that could only be plugged by turning off some of the features of IE6 that were not available in other browsers. Microsoft was forced to release Internet Explorer 7 simply because the patches that were needed to resolve all the security holes without completely disabling the features that gave IE the advantage over other browsers were too great to handle any other way.

The team working on the Netscape replacement code made the core of their browser code available as open source under the name Mozilla. As the dominant browser at the time was IE6 they decided to skip 5 in their numbering and released their next browser as Netscape 6 which was then followed by Netscape 7. Unfortunately by then they had lost their market and neither of these browser versions gained much market share as a proprietary browser. Their work survived though because there was subsequent development of the open source version of their code first as phoenix, then firebird and finally as Firefox. This new standards compliant browser running JavaScript did gain a significant market share and started to challenge Internet Explorer.

That they were now losing significant market share meant that Microsoft now had a reason to resume development of Internet Explorer beyond the security patches of IE7 and with Internet Explorer 8 they had a browser that was almost as standards compliant as the other browsers. One of the biggest differences was that IE8 still ran JScript where all the competing browsers ran JavaScript.

The nail in the coffin for JScript might have been when Google moved into the browser market and released Google Chrome (not to be confused with the browser chrome which is the part of the browser that is not the viewport). This browser gained market share quite rapidly and soon created a situation where no one browser dominated the browser market. What this did mean though was that with both Firefox and Google Chrome running JavaScript and Internet Explorer 8 running JScript that JavaScript did now dominate as far as scripting languages are concerned. When you consider that all of the minor browsers also run JavaScript the dominance of JScript was over.

Microsoft saw the writing on the wall for JScript and with Internet Exploer 9 they produced a browser that could run both JScript and JavaScript. This means that once Internet Explorer 8 finally dies out that there will be no reason for using feature sensing to check whether the browser supports JavaScript or JScript any more.

With Internet Explorer 10, Microsoft put the final nail in the coffin for JScript as with this version Internet Explorer now only supports JavaScript and JScript is not supported by the current version of any browser. JScript (which Microsoft originally developed as their answer to Netscape's JavaScript) is now dead.

On Site

Following from some feedback I received after the September newsletter I have started work on modifying the appearance of the newsletter. This is the first time I have updated the way the newsletter looks (apart from a few minor colour changes) since the first issue back in September 2000. You can expect to see further changes to the appearance of the newsletter in coming months and any further feedback is most welcome.

What's New

The following links will take you to all of the various pages that have been added to the site or undergone major changes in the last month.

Main Links

Ask Felgall
Past Newsletters
Sign Up/Unsubscribe
Question Forum


Interactive Web
PC Software
Comms Software
Word Processing
Book Reviews

Other Links

My Javascript Site
My Blog