function show(name,_left,_top){ // функция показа. аргументы name, x,y if(ie){ document.all[name].style.top=_top; // для IE обращение через all и style document.all[name].style.left=_left; document.all[name].style.visibility='visible'; } else{ document.layers[name].top=_top; // верхняя координата элемента document.layers[name].left=_left; // левая координата элемента document.layers[name].visibility='show'; // делаем "видимым" } }// конец функции function hide(name){ if(ie){ document.all[name].style.visibility='hidden'; // аналогично для IE } else{ document.layers[name].visibility='hide'; // делаем "невидимым" } }// конец функции function create_layer(name,vis) { if (vis) { var strvis = (ie) ? "visible" : "show"; } else { var strvis = (ie) ? "hidden" : "hide"; } if (ie) document.write('
'); else document.write(''); document.write(''); if (ie) document.write('
'); else document.write(''); } var ie = (navigator.appName.indexOf("Netscape") == -1) ? true : false; create_layer("map_applet", false); create_layer("map_applet_bar", false); if (ie) { var map_applet_bar_top = document.body.clientHeight/2 - (40/2); var map_applet_bar_left = document.body.clientWidth/2 - (100/2); var newwin_height = document.body.clientHeight; var newwin_width = document.body.clientWidth; } else { var map_applet_bar_top = window.innerHeight/2 - (40/2); var map_applet_bar_left = window.innerWidth/2 - (100/2); var newwin_height = window.innerHeight; var newwin_width = window.innerWidth; } function uuu(u){ applet_loading = false; window.w.focus(); } var w; function mapwrite(obj) { show("map_applet_bar", map_applet_bar_left, map_applet_bar_top); applet_loading = true; wait_load(); if(!w || w.closed){;}else{w.close();}; w=window.open(PREFIX+"/map/address.php3?object="+obj,"jjj","height="+newwin_height+",width="+newwin_width+",screenX=0,screenY=0,left=0,top=0,toolbar=1,scrollbars=1,menubar=1,resizable=yes,status=yes,directories=no,location=yes"); applet_loading = false; this.focus(); return false; } var applet_loading = true; function wait_load(){ if (applet_loading == false) { clearTimeout(id); hide("map_applet_bar"); } else { id = setTimeout('wait_load()', 500); } }