//FINAL COUNTDOWN!
var millisecs_per_day=86400000
// årstall, mnd (januar=0), dag, +GMT offset
var countdown_time=Date.UTC(2010,6,28,+2);
// get the current time and convert to milliseconds
var now=new Date();
var now_millisecs=now.valueOf();

var day_cnt= Math.ceil(( countdown_time - now_millisecs)/86400000 )

if ( day_cnt > 1 )
{
document.write( day_cnt + " days to go")
}
else if ( day_cnt == 1 )
{
document.write( day_cnt + " day to go")
}
else if ( day_cnt == 0 )
{
document.write( "The festival kicks off today")
}
else if ( day_cnt == -1 )
{
document.write("The second day of the festival")
}
else if ( day_cnt == -2 )
{
document.write("The third day of the festival")
}
else if ( day_cnt == -3 )
{
document.write("The fourth day of the festival")
}
else if ( day_cnt == -4 )
{
document.write("The fifth day of the festival")
}
else if ( day_cnt == -5 )
{
document.write("The sixth day of the festival")
}
else if ( day_cnt == -6 )
{
document.write("The last day of the festival")
}
else
{
document.write("The festival of 2010 is over")
}
