un piccolo esempio di classe js, vedi se va al caso tuo:
questa la metti in un file esterno o nell'head
codice:
/**
* CountDown Class
*
* @author Giovambattista Fazioli
* @email g.fazioli@undolog.com
* @web http://www.undolog.com
*
* @param dd (string) 'month day, year'
*
*/
function countDown( dd ) {
// init target time
var target = new Date( dd );
this.targetTime = target.getTime();
/**
* refresh countdown
*/
this.refresh = function() {
var today = new Date();
var currentTime = today.getTime();
// time left
this._leftMilliseconds = (this.targetTime - currentTime);
this._leftSeconds = Math.floor( this._leftMilliseconds / 1000 );
this._leftMinutes = Math.floor( this._leftSeconds / 60 );
this._leftHours = Math.floor( this._leftMinutes / 60 );
// no module
this.leftDays = Math.floor( this._leftHours / 24 );
// for print
this.leftMilliseconds = this._leftMilliseconds % 1000;
this.leftSeconds = this._leftSeconds % 60;
this.leftMinutes = this._leftMinutes % 60;
this.leftHours = this._leftHours % 24;
}
this.refresh();
}
questa dove vuoi far comparire il countdown:
codice:
var cd = new countDown( '1 1, 2009' );
// mostra quanti giorni, ore, minuti, secondi e millisecondi al primo gennaio 2009
document.write( cd.leftDays + "," + cd.leftHours + "," + cd.leftMinutes + "," + cd.leftSeconds + "," + cd.leftMilliseconds );
PS: basta googlare un pochetto e trovi subito quello che cerchi 
ciao
Riko87