Unit 3 – JavaScript
Features of JavaScript
- An interpreted language
- Embedded within HTML
- Minimal Syntax-Easy to learn(C syntax and java ooc)
- Mainly used for client side scripting because it is supported by all the browers
- Designed for programming user events
Difference between OOP and Object-based
Embedding JavaScript into HTML page
Deferred and Immediate Script
JavaScript-lexical structure
JavaScript-Variables
JavaScript-Implicit data types
JavaScript-Operators
JavaScript-Control structures
JavaScript-Loop
User defined Functions
Top-Level functions(window object functions)
In-built properties(window object property)
Dialog boxes(window object methods)
Objects
- Creating objects
- Date object
- Math object
- String object
- Arrays
JavaScript as a referenced file
- Embedded
- External file
- Inline
- The important use of the referenced file is
Reusable function can be placed in the .js file
Multiple pages can use the same .js file
Maintenance will be easier
HTML event Handlers

浙公网安备 33010602011771号