What You Need to Do
To use this applet yourself, download the source code file
. Next, publish the gallery.jar file into your Web site's directory on your Web server. Then, in the HTML pages for your site, insert a <APPLET ...> tag wherever you want to use the applet.
The following code makes a Web page that displays the pictures from my example in the previous section:
<applet code="Gallery" archive="gallery.jar"
width="300" height="400" name=gallery1>
<param name="image0" value="DMW-01.gif">
<param name="image1" value="DMW-02.gif">
<param name="image2" value="DMW-03.gif">
<param name="image3" value="DMW-04.gif">
<param name="mixers" value="ImageMixer, Burn, Butterfly, Smoke, Wipe">
Put something here for browsers that don't understand Java
The <PARAM ...> tag indicates that the applet requires some parameters, and each one requires a value. This is the only programming you have to do. The available parameters are as follows:
This parameter specifies the list of images used in the slide show. The parameters should be passed as image0, image1, image2, and so on. You can use as many images as you want.
These are the transition effects that the slideshow will use, given as a comma-separated list. The choices are "ImageMixer" (simple cross-fade), "Burn" (irregular fade, colored to resemble fire), "Butterfly" (expanding X fade), "Smoke" (irregular smoke-like fade), and "Wipe" (horizontal or vertical wipe).
So, for instance, if you want to use only "Smoke" and "ImageMixer", the mixers parameter should be set to "Smoke, ImageMixer". Be careful with the capitalization of the mixer names--if you get the cases of the letters wrong, they will not work. If you don't specify any mixers, then the applet uses them all.
If you want to use the applet as a hyperlink, set the href parameter to the URL for the page that you want users to go to when they click the applet.
This parameter is needed only if you use frames. If you use the applet as a link, then enter the name of the target frame into which the page will be loaded.
Gallery can use image maps from the page that contains it. For example, if you have a <MAP...> tag in a page called "fred", then you should set the map parameter to "fred" (not "#fred").
I suggest you put the gallery.jar file in the same directory as the page on which it will appear. If you want to move it elsewhere, use the "CODEBASE" option to point to the appropriate directory. Because the applet is stored in the gallery.jar archive file, you will need to add "archive=gallery.jar" into your applet statement, as in the code snippet above.