LevSelector.com |
This page shows how to get exact time (atomic clock) and how to show
time on your page.
On this page: | |
•
main_sites
• Navy • Misc • Code (Perl & Java) |
Main Sites | home - top
of the page - |
Try these (reload them to see how time changes):
• tycho.usno.navy.mil/cgi-bin/timer.pl
- my favorite, shows times in different zones
• time-a.timefreq.bldrdoc.gov:14/
-
• www.infosys.tuwien.ac.at/Services/AtomZeit/GimmeTheTime.pl
-
• www.worldtimeserver.com/
- shows time in different countries and cities around the globe
Use Javascript to put time on your page:
• javascript.internet.com/clocks/index.html
-
Browse many links related to time/clocks:
• www.panaga.com/clocks/clocks.htm
-
• www.time.gov/
- Boulder Atomic Clock (a link from nist.gov
- The National Institute of Standards and Technology)
• www.atomictime.net/
- different ways
Navy | home - top
of the page - |
• tycho.usno.navy.mil/
-
You can get text version here: • tycho.usno.navy.mil/cgi-bin/timer.pl
(you can parse it as you like to select the time you need).
It is updated every second.
( or you can get a GIF version of Universal Time
by calling • tycho.usno.navy.mil/cgi-bin/utc.gif
)
Here is how to convert from Universal Time:
• tycho.usno.navy.mil/zones.html
• tycho.usno.navy.mil/zones2.html
Same for DAYLIGHT-SAVING TIME:
• tycho.usno.navy.mil/zones3.html
• tycho.usno.navy.mil/zones4.html
Misc. | home - top
of the page - |
Code | home - top
of the page - |
Example getting time:
Perl:
# ------------------------------------------ # read time from time.gov # ------------------------------------------ use Socket;
my $remoteServer = 'www.time.gov';
# --------------------------
my($packFormat) = 'S n a4 x8'; # Windows 95, SunOs 4.1+
# --------------------------
exit(); # ------------------------------------------
|
Java:
// select one of the hosts: NIST.GOV or TIME.GOV or BLDRDOC.GOV
int daytimePort = 8013; // Get serverDateString using this method: private void GetServerDateString()
// Then get a long value as number of ms from 1970:
|