What is the JavaScript?
|
JavaScript is an scripting language for the client side web development means web pages. It is designed by Brenden Eich comes in 1995.Developer of JavaScripts are Netscape Communications Corporation, Mozilla Foundation. As name indicate you think it is essential related to Java. Its wrong its syntax matched with C Syntax,it use some java name and their convension. It is influenced by Seff,C,Scheme,Perl,Python,Java. Using this we can do many thimgs like: to improve Design,validate forms,detect browsers etc. JavaScript can be use by new programmer easily. I have given you some most important point related to JavaScript. - JavaScript is a trademark of Sun Microsystem.
- It is dynamic,Weak and prototype language.
- Using JavaScript we can make our HTML pages interactive.
- JavaScript is a scripting language.
- We can embedded JavaScript directly into HTML pages.
- It is an interpreted language means for execution their is no need to pre-compilation of JavaScript. Latest version of JavaScript is 1.8/ 2008
|
Is Java and JavaScript are same or not?
|
No, they are not. Java (developed by Sun Microsystems) is a powerful and much more complex programming language in the same category as C and C++. JavaScriptwas created by Brendan Eich at Netscape and was first introduced in December 1995 under the name of LiveScript. However, it was rather quickly renamed JavaScript, although JavaScripts official name is ECMAScript, which is developed and maintained by theECMA (European Computer Manufacturer\'s Association) International organization.
|
When we use JavaScript?
|
We use JavaScript when we want to perform several things like this- JavaScripts are simple pre compiled code.We use this code into the HTML pages to make interactive .It is easy to use.
- Using JavaScript we can set dynamic text into the HTML page.Example:document.write(\"+text+\")
- we can also set JavaSCript perform when some event happen means its automatically call when some special event execute.
- Using JavaScript we can read HTML element and changed the content of element.
- Using JavaScript we can validate the data before sending to to the server.Means that we can reduce the server Urocessing before using JavaScript.
- Using JavaScript we can identify the user\'s browser.
- Using JavaScript we can also create the cookie and used this cookies to store and retrieve info on user\'s system.
|
What are you understand about ECMAScript?
|
- ECMAScript is an official name of JavaScript.
- ECMA Organization developed and maintain ECMAScript.
- An official JavaScript standard is ECMA-262.Development to of this started in 1996 and It is first used in ECMA General Assembly in june 1996.
- It gets cettificated by international ISO (ISO/IEC 16262) standard in 1998.
- It is usually based on JavaScript and Jscript Repectively given by Netscape and Microsoft.First it is invented by Brendan Eich at Netscape and applied on Navigator 2.0 after 1996 it is used on all type of Netscape and micrisoft browser.
|
In HTML where JavaScript will executed?
|
When we write javaScripts inside the body that will execute when page load.If we write JavaScripts inside the head than it willexecuted when we called. When we put JavaScript with in head of HTML.Than JavaScript is executed when we called them.Example: /*Their is no limit to put a fixed number of JavaScripts on your page.You can use JavaScripts in both head and body together.*/<html><head><script type=\"text/javascript\">........</script></head><body><script type=\"text/javascript\">........</script></body> |
How to use an External JavaScript?
|
We use external JavaScript when we want to execute same JavaScripts on many pages.When we use external JavaScript using this their is no need to write JavaScripts on every page.
If we want to use JavaScript than we first write JavaScript in enternal file than save this external JavaScript file by using .js file extension.
External Script doesn\'t contain
|