JavaScript Programming

Course length: 3 daysReturn to Web Developer

 

Course description

Overview: Students will learn how to program by using JavaScript 1.3.

 

Prerequisites: To ensure your success, we strongly recommend you first take the  Software Training course, Enhancing Web Pages with JavaScript and have a strong familiarity with using the Internet, or should have extensive equivalent knowledge.

 

Delivery method: Instructor-led, group-paced, classroom-delivery learning model with structured hands-on activities.

 

Benefits: Students will learn how to write JavaScript programs that use the latest language techniques (version 1.3). Students will also learn how to write programs that are compatible with previous versions of the language and are cross-browser compatible.

 

Target student: Students enrolling in this course should have a strong understanding of HTML programming and should have a basic familiarity with JavaScript. They should have examined scripts written by others and have implemented other people's scripts on their web pages. This is a serious programming course for those students who want to gain a full understanding of this powerful programming language.

 

What's next: JavaScript Programming is the first course in this series. Advanced JavaScript Programming, the next course in this series, teaches students advanced language components and advanced programming techniques.

 

Performance-based objectives

Lesson objectives help students become comfortable with the course, and also provide a means to evaluate learning. Upon successful completion of this course, students will be able to:

·        List the JavaScript syntax rules and implement good coding practices.

·        List the data and variable types that JavaScript supports, use the many control statements available in JavaScript, and create and use functions.

·        Describe object characteristics, use objects, instantiate objects, and create custom objects.

·        Describe the purpose of the Document object and use its properties, methods, and event handlers.

·        Script with frames in mind.

·        Describe the purpose of the Form object and use its properties, methods, and event handlers to read and write to HTML forms.

·        Choose a general process for validating user input into web forms.

·        Validate user input into HTML forms including testing for required fields, numeric data and numeric data within a range of values specified, and string data.

·        Describe the purpose of the Date object, instantiate and use instances of the Date object to create clocks, count-down timers, and perform date math.

·        Describe the purpose of the Math object and use its constants and methods to perform mathematical operations.

·        Characterize the compatibility landscape and choose between the various techniques for dealing with potential incompatibilities. Detect browsers in order to create code that works around platform incompatibilities.

 

Course content

Lesson 1: Getting Started with JavaScript

JavaScript Overview

JavaScript Programming Overview

 

Lesson 2: JavaScript Building Blocks-Variables and Operators

Variables and Data Types Overview

Using Variables and Data Operators

 

Lesson 3: JavaScript Building Blocks-Control Statements

Controlling the flow - JavaScript Control Statements

 

Lesson 4: JavaScript Building Blocks-Functions and Objects

Functions

Objects

 

Lesson 5: The Window Object

The Window Object

Dialog Boxes

Status Bar Messages

Window Manipulations

 

Lesson 6: The Document Object

The Document Object

Writing to Documents

Dynamic Documents

 

Lesson 7: Working with Frames

HTML Frames Review

Scripting for Frames

 

Lesson 8: Working with Forms and Forms-based Data

The Form Object

Reading Data from Form Elements

 

Lesson 9: Validating Form Data

A General Approach

Testing for Required Fields

Validating Numeric Data

Validating String Data

 

Lesson 10: Dates and Math

Overview of the Date Object

Using and manipulating Dates

Overview of the Math Object

Doing Math with JavaScript

 

Lesson 11: Introduction to Cross-browser Compatibility

Examining the Compatibility Landscape

Detecting Browser and Platforms

 

Additional information: This course teaches cross-browser programming techniques, and thus requires both Internet Explorer and Navigator to be installed. Students will not be able to complete some exercises if they do not have access to both browsers.Return to Web Developer