An Abbreviated Introduction to JavaScript

[Overview] [Basics] [More] [Fun] [Class 2] [If] [Functions] [Timing] [Queries] [References] [Examples] [Libraries] [Assignments]


Class Two

Abstract: A summary of what has gone before, a few small new ideas, and what is to come.


Questions

A Request

After class, can someone please move the sample files to a place from which they'll be generally accessible?

A Few Short Notes

Loading Other Documents

Often, what we want to do after time has expired is to switch to another page (at least that's what we're going to do in our experiment). To do that, we assign a new url to the location object, as in location="results.html" or location="http://www.math.grin.edu/".

If I've stored someone's VAX user id in userid, I can switch to their home document with

location="http://www.grin.edu/~"+userid

The Status Bar

You may recall that we had some trouble with the status bar in the last class session. While the updates worked fine on my machine (an HP running Netscape 4.0), they didn't seem to work well on our Macintoshes running Netscape 3.0. One of you was kind enough to point out that we need a special syntax for updating the status bar in an a href tag. In addition to updating the status bar, you also need to return true. Why? Who knows.

Take a look at the updated example and the old example to see the differences.

Playing Sounds

Unfortunately, I was not able to figure out how to play sounds. I would guess that a clever use of loading other documents would help, but I'm not sure. My next few weeks are so overbooked that I don't think that I'd be able to come up with an implementation before the end of the term.


[Overview] [Basics] [More] [Fun] [Class 2] [If] [Functions] [Timing] [Queries] [References] [Examples] [Libraries] [Assignments]

Source text written by Samuel A. Rebelsky.

Source text last modified Wed Apr 8 10:42:46 1998.

This page generated on Wed Apr 8 10:52:51 1998 by SiteWeaver.