function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

var timerID = null;
var timerRunning = false;
var timerRun = false;
function stopclock (){
        if(timerRunning)
                cleartimeout(timerID);
                timerRunning=false;
				timerRun = false;
}
function startclock (){
        stopclock();
        showtime();
}
function showtime (){
        var now = new Date();
        var dow = now.getDay();
                if(dow == 0){
                        dow = "Воскресенье, ";
                } else {
                        if(dow == 1){
                                dow = "Понедельник, ";
                        } else {
                                if(dow == 2){
                                        dow = "Вторник, ";
                                } else {
                                        if(dow == 3){
                                                dow = "Среда, ";
                                       } else {
                                                if(dow == 4){
                                                       dow = "Четверг, ";
                                               } else {
                                                       if(dow == 5){   
                                                                dow = "Пятница, ";
                                                        } else {
                                                                dow = "Субота, ";
                                                        }}}}}}
        var month = now.getMonth() + 1;
                if(month < 10){
                        month = "0" + month;
                }
        var date = now.getDate();
                if(date < 10){
                        date = "0" + date;
                }
        var year = now.getYear();
        var hours = now.getHours();
        var minutes = now.getMinutes();
        var seconds = now.getSeconds();
		var timeVal="";
        var timeValue = " " + dow;
       timeValue += " " + date + "/" + month + "/" + year;
        timeVal += " " + ((hours > 12) ? hours  : hours);
        timeVal += ((minutes < 10) ? ":0" : ":") + minutes;
        timeVal += ((seconds < 10) ? ":0" : ":") + seconds + "   " + dow +" " + date + "/" + month + "/" + year;
        document.clock.face.value = timeVal;
        timerID = setTimeout("showtime()",1000);
        timerRunning = true;
		timerRun = true;
}