Javascirpt (JS) is a scripting language developed by Netscape and sun. Its syntax is very similar to that of Java.
1. js Purpose
As we all know, HTML is displayed to users as static pages, rigid and monotonous. At the same time, before JavaScript appears, all the processing required for Web pages must be returned to the server, when the traffic increases, the server load increases.
The emergence of JS solves these problems to a certain extent. JS can add dynamic effects to pages, and put some functions (such as data verification) on the client, which reduces the burden on the server.
2. js Development
Javascript developed by Netscape and sun has been well supported since its birth. Microsoft is not afraid to lag behind and has developed its own script, jscirpt. And have their own successive versions. However, the differences between the script version and the browser platform make it difficult for developers to choose between them and cause unnecessary troubles.
Therefore, Microsoft, Netscape, and so on decided to develop a standard together so that all scripts can comply with it. Therefore, ecmascirpt. JavaScript and jscirpt have both extended ecmascript.
3. js features
1). JS is embedded in HTML.
JS uses the <SCRIPT> </SCRIPT> label to embed it into HTML documents.
2). js requires Environment Support
JS is a language rather than a tool, so it must be supported by the environment. The so-called environment is nothing more than the JS interpretation engine. Only with the support of these interpretation engines can JS play a role.
Therefore, when using JS, you must consider whether the browser supports Js. If not, how should we solve this problem.
3). JS is interpreted and executed.
It is precisely because of the implementation of explanations that the web page is easier to maintain and update.
4). JS is a weak type language.
Variables in JS can be used without definition.
5). JS is object-based
There are custom objects in JS. These objects are all instantiated and can be used directly. However, objects in JS can only be used, rather than creating classes that inherit from these objects.
6). JS is not Java
JS interpretation and execution, Java compilation and execution, weak JS language, strong Java language, JS object-based, Java object-oriented.