function refObj(s){
  if(document.getElementById) return document.getElementById( s );
  else return eval('document.all.' + s);
}
var width0=width=screen.width;
var height=screen.height;
ww=((height<1000)?95:85);
//var ww=((height<1000)?99:93);
var hh=((height<1000)?100:70);
if(width/height>1.35){
var w_otn=56*2.3*height/width;  // 1.9
ww=Math.round(w_otn);
}
var dh=10;
if(height>1000)dh=70;
//----------------------
var urlsLab = ["mech/mechanic.html","molec/index.html","atomic/atomic.html","r_safety/ecology.html","design/index.html","demo/",
"../methods/lectures.html","english/atomic.html"];
var urlsMeth = ["lectures.html","phys_prac1.html","../work/Laser_lec/index.html","mex_lec.zip","tushev.zip","study.html","Savelev_3.pdf"];
var urlsLect = ["mech_pr.html","optic_pr.html","atom_pr.html"];
var urlsPage = ["methods/schedule.xls","methods/exam1.xls"];
//var urlsPage = ["http://www.csu.ru/files/физика%201%20сем%2010-11.xls","methods/exam1.xls"];
function dir0(k)
{
var nm,dr;
switch (k){
case 0: nm=urlsLab;dr="work/";break;
case 1: nm=urlsMeth;dr="methods/";break;
case 2: nm=urlsLect;dr="methods/";break;
case 3: nm=urlsPage;dr="";
}
var ind=refObj('sel'+k).selectedIndex-1;
if(ind<0)return;
var ph=nm[ind];
if(k==1&&ind>2&&ind<5)vis(ind-3);
else if(k<3)document.location.href = dr+ph;
else window.open(ph);
}
function dl(k)
{
if(k==0)window.open('others/'+urlsLink[k],"","width=500,height=190,scrollbars=no,left=150,top=150,titlebar=no");
else document.location.href = urlsLink[k];
}
function dg(k)
{
var ad = ["./question/index.php","./guestbook/guest.php","./wr-forum/index.php","./others/learning/learning.php","methods/articles.html","fpk/index.html"];
if(k==1)refObj('formg').submit();
else document.location.href = ad[k];
}
/*function showFoto(s,a)
{
im='<html><body><img border=0 width='+width0+' height='+(height-50)+' src="./others/imagesS/'+s+'" title="фото '+a+'" alt="foto"></body></html>';
alert('im= '+im);
document.write(im);
}*/

