Sample BillsClocks

View this page's source code to see the HTML applet tags used for each clock.

When you place this clock on your webpage, be sure to upload the following class and image files:

Remember, the image file must go in the same directory as the class files. Also, Java is case-sensitive. Do not change the names of the class files, or else the applet will ot run!

BillsClock.java is the source code file. You do not have to place this file on your web server. Only place the class files, and your image file (or the default image, java.gif) on your web server.

You may not be able to run this (or other applets) locally (from a file) using MSIE 3.02 because of a bug in that version of IE. The fix is either upgrade to IE 4, or upgrade IE 3.02's Java Virtual Machine. See http://www.microsoft.com/java for more information about upgrading the Java VM.

Note: By using this applet, you agree to the terms of its license agreement.


Example 1

This example sets US Central Standard Time (-6 hours) and also sets the clock background color to match this page.

Example 2

This example should display the browser's local time (LOCALONLY=1) and also sets the clock background color to match this page.

Example 3

This example displays Greenwich Mean Time (TIMEZONE=0) and shows how placing the applet in a one-celled table can create a border. The background is set to black in this example.


Proper operation of Bill's Clock has been confirmed on the following browsers/OS platforms:

Operating System Browser
Windows 95 IE 3.02, 4.01
Navigator 3.04, 4.05, 4.5
Windows NT 4.0 IE 4.01
Navigator 4.5
Sparc/Solaris 2.5.1 Navigator 4.5
Intel/Solaris 2.6 Navigator 4.05
MacOS 8.1 IE 4.01
Navigator 4.07
MRJ 2.0 Applet Runner

Note: Bill's Clock did not display correct time with Navigator 3.1 on the Mac. This is not an applet bug.

HTML Applet Parameters

Parameter Name

Data Type

Description

WIDTH int applet width in pixels
HEIGHT int applet height in pixels
BGCOLOR string Hex RGB triplet of background color, i.e. 000000 for black <black>
FACECOLOR string Hex RGB triplet of clock face, i.e. 000000 for black <black>
SWEEPCOLOR string Hex RGB triplet of second hand, i.e. FF0000 for red <red>
MINUTECOLOR string Hex RGB triplet of minute hand, i.e. C0C0C0 for light gray <light gray>
HOURCOLOR string Hex RGB triplet of hour hand, i.e. FFFFFF for white <white>
TEXTCOLOR string Hex RGB triplet of numerals, i.e. FFFFFF for white <white>
CASECOLOR string Hex RGB triplet of case, i.e. 000000 for black <black>
TRIMCOLOR string Hex RGB triplet of case, i.e. 000000 for black <black>
BGIMAGEURL string Name of background image file, if any <null>
LOGOSTRING string Text to display on clock face <J***X>
LOGOIMAGEURL string File name of of logo image to display on clock face <null>
TIMEZONE real Timezone difference to GMT (Decimal hours, - if West of Greenwich Meridian, + if East.) <0>
LOCALONLY int If non-zero, forces clock to display viewer's local time, with no timezone correction. Any timezone offset will be disregarded. <0>

Copyright © 1996-98 by Bill Giel / Moondog Software. All Rights Reserved.