  var pImgLink = '';

iTransp=new Image();
iTransp.src="/pict/transp.gif";
iPoint=new Image();
iPoint.src="/pict/point.gif";
iWait=new Image();
iWait.src="/pict/_wait.gif";

function MM_showHideLayers(lrName, lState) {
  lrObj = document.getElementById(lrName);
  lrObj.style.visibility = (lState=='show'?'visible':'hidden');
}

function iCh(iNum)
{
  for (i=1; i<=15; i++) {
    imgName = "iMenu"+i;
    document.getElementById(imgName).src = iTransp.src;
  }
  imgName = "iMenu"+iNum;
  document.getElementById(imgName).src = iPoint.src;
}

function lShow(lNum)
{
  for (i=0; i<=15; i++) {
    MM_showHideLayers('SubMenu'+i,'hide');
  }
  MM_showHideLayers('SubMenu'+lNum,'show');
}

function sImage(iName,iLay)
{
  pImgLink = iName+".shtml";
  imgName = "prev_img/"+iName+".gif";
  document['pPict'].src = iWait.src;
  document['pPict'].src = imgName;
}

function pLink()
{
  if(pImgLink == '') {
    window.status = "---- NOTHING TO SHOW ----";
  }
  else {
    window.location = pImgLink;
  }
}

function iNewWnd(imgSrc) {
	x_win = open("", "x_win", "resizable,width=100,height=100,top=0,left=0");
	var bod = x_win.document.getElementsByTagName('body')[0];
	bod.innerHTML='';
	img = new Image();
	img.onload = function() {
		setTimeout(function() {
    		var bod = x_win.document.getElementsByTagName('body')[0];
   	 		bod.style.margin=0;
   	 		bod.style.padding=0;}, 0);	
		if (navigator.appName!='Microsoft Internet Explorer') {	
			x_win.resizeTo(w = img.width+10, h = img.height+80);}
		else {
			x_win.resizeTo(w = img.width+10, h = img.height+90);	
		}
		x_win.moveTo((document.body.clientWidth - w)/2, (document.body.clientHeight - h)/2);	
		if (img.outerHTML ) x_win.document.write(img.outerHTML);
		else x_win.document.body.appendChild(img);	
	}
	img.src = "/"+imgSrc; 
	x_win.focus();
}