Programming

Learn to use native browser formats and plug-ins to view
and borrow or create small programs to add to your own Web pages.


What are Java and JavaScript?

Both Java and JavaScript are programming languages that you can use to add interactivity to your Web pages. But don't panic at the term "programming"; there are lots of Java and JavaScripts available on the Web that you can copy and modify for your own use with a minimum of efforts.

What is different about Java and Javascript?

JavaScript: Netscape invented JavaScript as a way to control the browser and
add interactivity to Web pages. Microsoft also implemented a version of JavaScript.
(See Netscape's Official JavaScript Site)

Java: Sun Microsystems invented Java as a full featured programming language (like C++).
(See Sun's Official Java Site)

Play

How are JavaScripts Played?

JavaScript is built into browsers and the little programs, called "scripts," are often placed right in the HTML page. (Like Hypertalk in HyperCard.) You can identify JavaScripts because they are usually embedded inside a <script> tag, and often are located in the HTML <head> section.

How are Java applets played?

Java can work without a browser. When Java programs are written to work with browsers, they are called "applets." They are in special files and then called from within the HTML page using the <applet> tag.

Add Java(s)

The good news is that both JavaScript and Java are relatively easy to borrow, and there are LOTS of places on the Net that are set up just for this purpose! Furthermore, the directions are generally included, and "relatively" clear, so you can accomplish a lot with just a little patience. Yahoo always has a lot of links to great places to go hunting for neat JavaScript and Java tricks (and a lot of others too)!!!

Here is one really great site to get started with JavaScript!

http://javascript.internet.com/

Then there are many others to choose from like these:
http://www.bodo.com/JavaScripts/index.html
http://www.js-planet.com/

Here are a few simple borrowed scripts: clock, calculator, popup

Here is an example of a famous Java applet that can be borrowed: lake

Here are some places where you can borrow Java applets:
http://www.intel.com/home/funstuff/webapplets/
http://www.captainjava.com/applets.html
http://www.free-applets.com/applets-links.html
http://www.wsabstract.com/cutpastejava.htm

See Applets Castro p. 220 (alt. p. 237)

Edit (Javascript Only)

One of the best ways to learn JavaScript is simply to look at
existing scripts like the ones above, and try to play with them.

(Note: Editing and creating Java applets is beyond the scope of this course.)

Create (Javascript Only)

JavaScript is actually very simple to get started using!

Check out these "Stupid Broswer Tricks" :)

Once you are comfortable playing with simple commands,
you might want to learn a little more formally.
Here is a very basic introduction to basic JavaScript concepts:
Webteacher Beginner's Guide to Javascript
Netscape maintains a site intended to help you do that:
Netscape Javascript Guide

You can also learn more advanced techniques by examining other sites.
Here is a special example from Lesley: Interactive Map and Photo Tour

  • See Scripts Castro Ch. 16 pp. 267-275 (alt. p. 17, pp. 291-299)
  • See Intrinsic events Castro p. 322 (alt. pp. 294, 295, 368)

    Other Programming Languages and the Web

  • CGI/Perl (Borrow some here! )
  • Visual C++ and Basic