function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() {
	if (document.images && (preloadFlag == true)) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

var preloadFlag = false;
function preloadImages() {
	if (document.images) {
		aover = newImage("_/a1a.gif");
		aaover = newImage("_/a2a.gif");
		aaaover = newImage("_/a3a.gif");
		preloadFlag = true;
	}
}
//moz=window.navigator.appCodeName == "Mozilla"
//moz=(navigator.appName == "Netscape") && DOM == Netscape6 == Mozilla
//isMozilla=isDOM && navigator.appName=="Netscape" //Mozilla / Netscape 6.*
//moz=window.navigator.appCodeName
ns=window.navigator.appName == "Netscape4"
ie=window.navigator.appName == "Microsoft Internet Explorer"
moz=window.navigator.appName == "Mozilla"
ienum=ie.appVersion;

function openIt(x) {
if(ns) {
   showbox= document.layers[x+1]
     showbox.visibility = "show";
	showbox.top ="15";

    var items = 5      
     for (i=1; i<=items; i++) {
      elopen=document.layers[i]
        if (i != (x + 1)) { 
          elopen.visibility = "hide";
		}
            }
  }    

if(ie) {
//document.write("IE");
   curEl = event.toElement
   showBox = document.all.box[x];
     showBox.style.visibility = "visible";

showBox.style.left="15";
         
   var items = 6 
    for (i=0; i<items; i++) {
      elOpen=document.all.box[i]
	    elOpen.style.zIndex = "2" 
        if (i != x){ 
          elOpen.style.visibility = "hidden";
		
     
       }
     }
   }
   
   if(moz) {
   //curEl = event.toElement

   document.write("Moz");
   
   showBox = document.getElementById.box[x];
   
     showBox.style.visibility = "visible";

showBox.style.left="15";
         
   var items = 6 
    for (i=0; i<items; i++) {
      elOpen=document.getElementById.box[i]
	    elOpen.style.zIndex = "2"; 
        if (i != x){ 
          elOpen.style.visibility = "hidden";
		 }
     }
   }
}

function closeIt() {
   var items = 6 
     for (i=0; i<items; i++) {
       if(ie){
        document.all.box[i].style.visibility = "hidden"
       }
       if(ns){ document.layers[i+1].visibility = "hide"}   
	 //  if(moz){ document.getElementById.box[x].visibility = "hidden"}         
}

}
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);

i=0; 
img_a=new Array() 
img_h=new Array() 
img_a[0]=new Image() 
img_a[1]=new Image() 
img_a[2]=new Image() 
img_a[3]=new Image()
img_a[0].src="/_/_.gif" 
img_a[1].src="/img/banner/stoimost1.jpg" 
img_a[2].src="/img/banner/stoimost2.jpg" 
img_a[3].src="/img/banner/stoimost3.jpg" 
function img_b() 
{ 
//document.images[0].src=img_a[i].src 
//document.images[0].src=img_a[i].src 
document.images.ban.src=img_a[i].src 
i++ 
if(i>3) i=0; 
setTimeout("img_b()", 3000) 
} 