Java on hermite
- Logon a PC in the computer lab, using either your account or
csc112a0 (ask Ileana for the password).
- Telnet to hermite.csc.smith.edu and logon hermite using your
112b-ax account (distributed bt Ileana in the beginning of the first
lab) ("x" in 112b-ax stands for a letter such as a,b,c, etc. and
the whole name corresponds for your class account).
- Go to the public_html directory (cd public_html).
- Go into a directory where you will be doing the current java
work (e.g. cd Lab1).
- Use emacs to create the HTML file and the java file. E.g.
- Compile with the JDK compiler, javac. E.g.
The resulting file will be a class file, e.g. myApplet.class.
- Make sure the permissions on the html and class files are OK
(i.e. everybody can read these files). Use
ls -l *.html *.class
to see these permissions. If they are not OK, change them with
chmod a+r myApplet.class
chmod go+r myApplet.class
- To view the applet, launch Netscape (from the PC desktop). Go
to the html page you have created. E.g.
- If you get an error, look into the Java console for more
details. To see the Java console, select Communicator/Java
Console from the Netscape menu.
- To make corrections, go back to the telnet window. Edit and
compile again your java file.
CAREFUL: if you go back to
Netscape and reload the page, the applet is not reloaded and you
will see the old version of your applet (before corrections). You
will have to close Netscape and launch it again. To simplify this
process, set it to always go to the last visited page, by
selecting Edit/Preferences/last page visited from the Netscape