JavaScript Lesson

October 17, 2002

Some good references for JavaScript are:

JavaScript for the WWW (4th edition)

Core JavaScript Guide 1.5

Core JavaScript Reference 1.5

Doc JavaScript

Peter-Paul Koch's Javascript Site

Visual Quickstart Guide

Web Teacher

Javascript — Pop up windows:

JavaScript is Object Oriented:

Consists of three parts:	OBJECTS,   METHODS,   PROPERTIES:

OBJECTS: a thing (NOUN / OWNER) Web page itself, table, form, button, image, link (Things that we interact with in scripts).
PROPERTIES: information ABOUT those objects (NOUN / OWNED) Things we can manipulate (window has title, form has a checkbox, cat has fur). * PROPERTIES Can Modify objects OR be applied to different objects... cat.fur window.title cat.paws.front.left
METHODS: things the objects CAN DO (VERBS) buttons CLICK() windows OPEN() cats PURR() () parentheses indicate that we are referring to a method instead of a property. object.method(arguments) cat.meow()
EVENTS: How we trigger our functions to run Actions that the USER performs while on your page. Commands called Event Handlers ** IMAGES CANNOT HAVE EVENTS, but THEIR LINKS CAN!! **
JavaScript uses DOT SYNTAX (separated by dots) computer.disk.floppu window.status cat.purr() onClick="run_my_function"(), name) onMouseOver document.write("Welcome to my page!") onLoad object.method()



It cannot contain spaces or puncutation.

It cannot be the reserved JavaScript Words.

Back to Syllabus  |   Sound on the Web  |   Animated Gifs