<!--

var DayNam = new Array( "воскресенье","понедельник","вторник","среда","четверг","пятница","суббота")
var MnthNam = new Array( "января","февраля","марта","апреля","мая","июня","июля","августа","сентября","октября","ноября","декабря")

function tick() {
 var hours, minutes, seconds, ap;
 var intHours, intMinutes, intSeconds;  var today;
 privet = ''
 today = new Date();
 intDay = today.getDay();
 intDate = today.getDate();
 intMonth = today.getMonth();
 intYear = today.getYear();
 intHours = today.getHours();
 intMinutes = today.getMinutes();
 intSeconds = today.getSeconds();
 timeString = DayNam[intDay] + '<span class="normwhite13">' + ' | ' + '</span>' + intDate;
 if((intHours >= 5) && (intHours < 12)) privet="Доброе утро!&nbsp;&nbsp;Сегодня:&nbsp;&nbsp;"
 if((intHours >= 12) && (intHours < 18)) privet="Добрый день!&nbsp;&nbsp;Сегодня:&nbsp;&nbsp;"
 if((intHours >= 18) && (intHours < 23)) privet="Добрый вечер!&nbsp;&nbsp;Сегодня:&nbsp;&nbsp;"
 if((intHours >= 23) || (intHours < 5)) privet="Доброй ночи!&nbsp;&nbsp;Сегодня:&nbsp;&nbsp;"
 if (intDate == 1 || intDate == 21 || intDate == 31) {
   timeString= timeString + '';
 } else if (intDate == 2 || intDate == 22) {
   timeString= timeString + '';
 } else if (intDate == 3 || intDate == 23) {
   timeString= timeString + '';
 } else {
   timeString = timeString + '';
 } 
 if (intYear < 2000){
    intYear += 1900;
 }
 timeString = timeString + ' ' + MnthNam[intMonth] + ' ' + intYear + '<span class="normwhite13">' + ' | ' + '</span>';
 if (intHours == 0) {
    hours = "24:";
    ap = '';
 } else if (intHours < 24) { 
    hours = intHours + ":";
    ap = '';
 } else if (intHours == 24) {
    hours = "24:";
    ap = '';
 } else {
    intHours = intHours - 24
    hours = intHours + ':';
    ap = '';
 }
 if (intMinutes < 10) {
    minutes = '0' + intMinutes;
 } else {
    minutes = intMinutes;
 }
 if (intSeconds < 10) {
    seconds = ':0' + intSeconds;
 } else {
    seconds = ':' + intSeconds;
 }
 timeString = (document.all) ? timeString + hours + minutes + seconds  + ap:timeString + ' ' + hours + minutes + ' ' + ap;
 var clock = (document.all) ? document.all('Clock') : document.getElementById('Clock');
 document.getElementById(clock.id).innerHTML = '<span class="boldwhite13">' + privet + timeString + '' +'</span>';
 (document.all) ? window.setTimeout('tick();', 1000) : window.setTimeout('tick();', 6000);
}
//clock.innerHTML
tick();

//-->

