Live Digital Clock II

clockclockclockclockclockclockclockclockclock


Questo orologio usa digit in formato gif ed è aggiornato ogni secondo. Copia questo codice nella tua pagina. Non dimenticare i digits! Devono essere chiamati: da 0dg.gif a 9dg.gif, dgam.gif, dgpm.gif e dgon.gif per i due punti. TUTTE LE GIF devono essere nella stessa cartella.
Live digital clock with gif digits. Updated every 1000 msec. Copy and paste the following code into you page. Don't forget the digits: name Odg.gif to 9dg.gif. Plus dgam.gif, dgpm.gif dgon.gif and space.gif.
Gifs MUST be in the same directory

Un'ottima collezione di digit
For a great collection of digits, visit Digitmania


Copy and paste this script into your HTML:

<script language="JavaScript">
<!-- Hide the script from old browsers --
img = new Array()
for(var i=0; i <= 14; i++) {
        img[i] = new Image()
}
img[1].src = "dg0.gif"
img[2].src = "dg1.gif"
img[3].src = "dg2.gif"
img[4].src = "dg3.gif"
img[5].src = "dg4.gif"
img[6].src = "dg5.gif"
img[7].src = "dg6.gif"
img[8].src = "dg7.gif"
img[9].src = "dg8.gif"
img[10].src = "dg9.gif"
img[11].src = "dgon.gif"
img[12].src = "dgoff.gif"
img[13].src = "dgam.gif"
img[14].src = "dgpm.gif"
var base = "dg"
var space = "space.gif"

var per = false
function stop() {
        document.one.src = space
        document.two.src = space
        document.three.src = space
        document.four.src = space
        document.five.src = space
        document.six.src = space
		document.seven.src = space
		document.eight.src = space
		document.nine.src = space
        per = false
}
function pause() {
        per = false
}

function go() {
        per = true
        start()
}
function start() {
        if(per == true) {
                var now = new Date()
                var hours = now.getHours();
              var ampm = (hours < 12) ? "am" : "pm"
                hours = (hours > 12) ? (hours - 0) + "" : hours + ""
                hours = (hours == "0") ? "12" : hours
                hours = (hours < 10) ? "0" + hours : hours + ""
                var minutes = now.getMinutes();
                minutes = (minutes < 10) ? "0" + minutes : minutes + ""
                var seconds = now.getSeconds();
                seconds = (seconds < 10) ? "0" + seconds : seconds + ""
                document.one.src = (hours.charAt(0)=="0") ? space : add(hours.charAt(0))
                document.two.src = add(hours.charAt(1))
                document.three.src = (now.getSeconds() % 2) ? add("on") : add("off")
                document.four.src = add(minutes.charAt(0))
                document.five.src = add(minutes.charAt(1))
				document.six.src = add("on")
				document.seven.src = add(seconds.charAt(0))
				document.eight.src =add(seconds.charAt(1))
                document.nine.src = add(ampm)
                setTimeout("start()",1000)
        }
}

function add(it) {
        return "dg" + it + ".gif"
}

// -- End Hiding Here -->
</script>
Adesso copia questo nel body code.
Now, copy this into the <BODY> code

<body onLoad="go()">
Ad esempio:
<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#FF0000" VLINK="#000080" ALINK="#000080" onLoad="go()">


Adesso copia questo script nella pagina HTML, nel punto dove vuoi che appaia l'orologio
Now paste this script in your page: put it exactly where you wish the clock to appear

<img src="space.gif" width=18 height=23 alt="clock" name="one"><img src="space.gif" width=18 height=23 alt="clock" name="two"><img src="space.gif" width=14 height=23 alt="clock" name="three"><img src="space.gif" width=18 height=23 alt="clock" name="four"><img src="space.gif" width=18 height=23 alt="clock" name="five"><img src="space.gif" width=14 height=23 alt="clock" name="six"><img src="space.gif" width=18 height=23 alt="clock" name="seven"><img src="space.gif" width=18 height=23 alt="clock" name="eight"><img src="space.gif" width=18 height=23 alt="clock" name="nine">

HomePage Top of Page
This page hosted by Get your own Free Home Page Back