/* (c)1999 Friedrich & Voss GbR */

function openWindowNav(theURL) { 
  var windowNav=null;
  windowNav=window.open(theURL,'Navigator','width=260,height=100,dependent=yes');
  windowNav.moveTo(0,0);
  windowNav.focus(); }

function openWindowMap(theURL) { 
  var windowMap;
  windowMap=window.open('/has/cgi-bin/vacuum_display_'+theURL+'.pl','map','width=372,height=500,dependent=yes');
  windowMap.moveTo(500,0);
  windowMap.focus(); }

function openWindowClock() { 
  var windowClock;
  windowClock=window.open('clock.html','clock','width=110,height=100,dependent=yes');
  windowClock.moveTo(350,0);
  windowClock.focus(); }


var winNo=0;
var beamline=0;
function openDisplay(machine) { 
 if (document.Formular[machine][0].selected == true){alert("Please select a beamline!")}
 else {
  for (var i = 0 ; i <= 2 ; i++) 
   {if (document.Formular.window[i].checked == true) {var winNo = document.Formular.window[i].value};}
  if (winNo == 1) {ii = 1};
  if (winNo == 2) {ii = 2};
  if (winNo == 3) {ii = 0};
  document.Formular.window[ii].checked = true;
  for (var j = 0 ; j <= document.Formular[machine].length - 1 ; j++) 
   {if (document.Formular[machine][j].selected == true) {var beamline = document.Formular[machine][j].value};} 	 
  display = window.open('http://adweb.desy.de/has/cgi-bin/vacuum_display.pl?call=n&window='+winNo +'&beamline='+beamline,'w'+winNo,'width=750,height=225,dependent=yes');
  display.moveTo(-20+winNo*20,150+winNo*50);
  display.focus();
 }
}


function openWindowX(theURL) { 
  alert("Webdesign by Friedrich & Voss Internet Services -> www.webdoc.de")}

