function popup(ptype, id1, id2) {
	var base_url='/tasks/pub';
	var scrollbars='no';
	var resizable='no';

	switch(ptype)
	{
	 case 'c_star':
	  var url=base_url+'/c_star.php?uid='+id1;
  	  var width=450;
	  var height=245;
	 break;
	 case 'trans':
	  var url=base_url+'/trans.php?pid='+id1+'&lid='+id2;
  	  var width=500;
	  var height=300;
	  var scrollbars='yes';
	  var resizable='yes';
	 break;
	 case 'etrans':
	  var url='http://babelfish.altavista.com';
  	  var width=520;
	  var height=500;
	 break;
	 case 'undock':
	  var url=base_url+'/undock.php?pid='+id1;
  	  var width=500;
	  var height=350;
	 break;
	 case 'exif':
	  var url=base_url+'/exif.php?pid='+id1;
  	  var width=500;
	  var height=300;
	  var scrollbars='yes';
	  var resizable='yes';
	 break;
	 case 'calib':
	  var url=base_url+'/calib.php';
  	  var width=540;
	  var height=500;
	 break;
	 case 'map':
	  var url='/mapcity.php?mtype=e&lat='+id1+'&long='+id2;
  	  var width=640;
	  var height=480;
	 break;
	 case 'cmap':
	  var url='/mapcity.php?lat='+id1+'&long='+id2;
  	  var width=640;
	  var height=480;
	 break;
	 case 'viewcode':
	  var url=base_url+'/viewcode.php?thid='+id1;
  	  var width=450;
	  var height=150;
	 break;
	 default:
	 break;
	}
	
	window.open(url, 'window', 'toolbar=no,status=no,width='+width+',height='+height+',scrollbars='+scrollbars+',location=no,resizable='+resizable+',menubar=no');
}

function toggle(whichLayer,cname)
{
	if (document.getElementById)
	{
		var x = document.getElementById(whichLayer).style;
			if ( x.display == "block") {
				x.display = "";
					cname.className="hide2";
					}
				else {
				x.display = "block";
				cname.className="hide1";
		}
	}
}