<!-- //
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) {
		over1 = newImage("images/over1.gif");
		preloadFlag = true;
	}
}

ag=navigator.userAgent;
if (!((t1=ag.indexOf("MSIE"))!=-1 && (t2=ag.indexOf("lla/2."))!=-1) && !((t3=ag.indexOf("lla/3."))!=-1)){
	Hh = screen.height;
	Ww = screen.width;
}else{
	Hh = 400;
	Ww = 500;
};
w = null;
wh = null;

function doCloseWindow()
{
	if (!w || (w.closed))
          { }
         else
          {
            w.close()
          }
}

function showimg(str_scr, strw, strh)
{
	if(w) { w.close(); }
	if (!w || (w.closed))
    {
       woffset = 0;
       wheight = 500;
       if (!((t1=ag.indexOf("MSIE"))!=-1 && (t2=ag.indexOf("lla/2."))!=-1) && !((t3=ag.indexOf("lla/3."))!=-1))
            {	
               woffset = Ww - 200;
               wheight = Hh - 50;
            }
		w = window.open(str_scr,"XXX","toolbar=no,location=no,menubar=no,scrollbars=no,resizable=no,width="+strw+",height="+strh+",screenY=0,screenX="+woffset);
	}
//    	w.focus();
}
function winop(im, w, h) {
windop=window.open("","mywin","width="+w+",HEIGHT="+h+"");
windop.document.open();
windop.document.write("<body LEFTMARGIN=0 MARGINWIDTH=0 TOPMARGIN=0 MARGINHEIGHT=0 bgcolor=ffffff><center><IMG SRC="+im+" BORDER=0 onClick=window.close(); alt=Закрыть окно>");
windop.document.write("</body>")
windop.document.close();
}

function toggleLayer(whichLayer) {
	if (document.getElementById) { var style2 = document.getElementById(whichLayer).style; }
	else if (document.layers) { var style2 = document.layers[whichLayer].style; }
	else if (document.all) { var style2 = document.all[whichLayer].style; }
	if (style2.display =='block') {
		style2.display = 'none';
	}
	else {
		style2.display = 'block';
	}
}
// -->