JavaScript_A Beginner's Guide - Introduction to JavaScript - 09/19/2012
2012-09-19 20:52
387 查看
Of course, you can build a Web page by using only HTML, but JavaScript allows you to add additional features that a static page of HTML can’t provide without some sort of scripting or programming help.
JScript is the version of JavaScript that Microsoft Internet Explorer uses (which has additional features because it is implemented as a Windows Script engine; it can use server side languages to perform more complex tasks like updating databases).
ECMAScript is the international standard name and specification for the JavaScript language, so it’s not a new language but a standard that is set for JavaScript and JScript
JavaScript and Java are two different languages. Java is a full programming language that must be compiled (running a program through software that converts the higher-level code to machine language) before a program (often called a Java applet) can be executed.
Java is more powerful but also more complex.JavaScript is an object-based, client-side scripting language that you can use to make Web pages more dynamic.
Object based means that JavaScript can use items called objects. However, the objects are not class based (meaning no distinction is made between a class and an instance); instead, they are just general objects.
Client side means that JavaScript runs in the client (software) that the viewer is using, rather than on the Web server of the site serving the page. In this case, the client would be a Web browser. With a client-side language, the browser reads and interprets
the code, and the results can be given to the viewer without getting information from the server first. This process can make certain tasks run more quickly
JavaScript can also be used to check the information entered into a form before the form is sent to a server-side program to be processed. This information check can prevent strain on the Web server by preventing submissions with inaccurate or incomplete
information. Rather than running the program on the server until the information is correct, that data can be sent to the server just once with correct information.
A scripting language doesn’t require a program to be compiled before it is run. All the interpretation is done on-the-fly by the client.
JavaScript runs in the browser by being added into an existing HTML document (either directly or by referring to an external script file). You can add special tags and commands to the HTML code that will tell the browser that it needs to run a script. Once
the browser sees these special tags, it interprets the JavaScript commands and will do what you have directed it to do with your code. Thus, by simply editing an HTML document, you can begin using JavaScript on your Web pages and see the results.
To find additional information online to help you with JavaScript, here are some useful resources:
● A place to find tutorials with working examples of the results:
www.pageresource.com/jscript
● An excellent tutorial site that includes cut-and-paste scripts:
www.javascriptkit.com
● Video series: http://channel9.msdn.com/Series/Javascript-Fundamentals-Development-for-Absolute-Beginners
First JavaScript program
JScript is the version of JavaScript that Microsoft Internet Explorer uses (which has additional features because it is implemented as a Windows Script engine; it can use server side languages to perform more complex tasks like updating databases).
ECMAScript is the international standard name and specification for the JavaScript language, so it’s not a new language but a standard that is set for JavaScript and JScript
JavaScript and Java are two different languages. Java is a full programming language that must be compiled (running a program through software that converts the higher-level code to machine language) before a program (often called a Java applet) can be executed.
Java is more powerful but also more complex.JavaScript is an object-based, client-side scripting language that you can use to make Web pages more dynamic.
Object based means that JavaScript can use items called objects. However, the objects are not class based (meaning no distinction is made between a class and an instance); instead, they are just general objects.
Client side means that JavaScript runs in the client (software) that the viewer is using, rather than on the Web server of the site serving the page. In this case, the client would be a Web browser. With a client-side language, the browser reads and interprets
the code, and the results can be given to the viewer without getting information from the server first. This process can make certain tasks run more quickly
JavaScript can also be used to check the information entered into a form before the form is sent to a server-side program to be processed. This information check can prevent strain on the Web server by preventing submissions with inaccurate or incomplete
information. Rather than running the program on the server until the information is correct, that data can be sent to the server just once with correct information.
A scripting language doesn’t require a program to be compiled before it is run. All the interpretation is done on-the-fly by the client.
JavaScript runs in the browser by being added into an existing HTML document (either directly or by referring to an external script file). You can add special tags and commands to the HTML code that will tell the browser that it needs to run a script. Once
the browser sees these special tags, it interprets the JavaScript commands and will do what you have directed it to do with your code. Thus, by simply editing an HTML document, you can begin using JavaScript on your Web pages and see the results.
To find additional information online to help you with JavaScript, here are some useful resources:
● A place to find tutorials with working examples of the results:
www.pageresource.com/jscript
● An excellent tutorial site that includes cut-and-paste scripts:
www.javascriptkit.com
● Video series: http://channel9.msdn.com/Series/Javascript-Fundamentals-Development-for-Absolute-Beginners
First JavaScript program
<html> <body> <script type="text/javascript"> document.write("This text was written with JavaScript!"); </script> </body> </html>
相关文章推荐
- JavaScript_A Beginner's Guide - Understanding variables - 09/21/2012
- JavaScript_A Beginner's Guide - Understanding Functions - 09/22/2012
- JavaScript_A Beginner's Guide - Conditional Statements and Loops - 09/23/2012
- JavaScript_A Beginner's Guide - Using an external JavaScript file - 09/20/2012
- Objective-c Beginner's Guide
- Objective-C Beginner's Guide
- Mastering Debugging in Visual Studio 2010 - A Beginner's Guide
- cocos2d-x by Example Beginner's Guide 第5章 Rocket Through
- Mastering Debugging in Visual Studio 2010 - A Beginner's Guide
- Microsoft Exchange Server 2007: A Beginner's Guide (Paperback), (Network Professional's Library) Aug.2007.eBook-BBL
- Ogre1.7 Beginner's guide
- 《MooTools 1.2 Beginner's Guide》
- cocos2d-x by Example Beginner's Guide 第5章 Rocket Through 之 粒子系统
- selenium 1.0 Testing Tools:Beginner's guide 已完成- selenium 1.0初学者指南
- vs2012 error c4996: 'fopen': This function or variable may be unsafe
- Linux-world-2012-January->13(error: 'S3C24X0_GPIO' has no member named 'GPACON')
- LCD 19' Monitor
- JavaScript 给变量初始化null ,隐式转换为 'null'
- ZooKeeper Quota's Guide