function openWindow(url) {
  popupWin = window.open(url, 'remote', 'scrollbars,menubar,resizable,dependent,width=640,height=480,left=100,top=100')
 popupWin.focus();
}

function openWindow2(url, remote, size) {
  popupWin = window.open(url , remote , size , ' scrollbars,menubar,resizable,dependent,left=100,top=100')
 popupWin.focus();
}

<!-- hide from JavaScript-challenged browsers

function openhelp(url, name) {
  popupHelp = window.open(url, name, 'scrollbars,resizable,dependent,width=457,height=300,left=100,top=100')
  popupHelp.focus();
}


// Heinle's function for retrieving a cookie.
function getCookie(name){
  var cname = name + "=";               
  var dc = document.cookie;             
  if (dc.length > 0) {              
    begin = dc.indexOf(cname);       
    if (begin != -1) {           
      begin += cname.length;       
      end = dc.indexOf(";", begin);
      if (end == -1) end = dc.length;
        return unescape(dc.substring(begin, end));
    } 
  }
  return null;
}

// An adaptation of Dorcht's function for setting a cookie.
function setCookie(name, value, expires, path, domain, secure) {
  document.cookie = name + "=" + escape(value) + 
  ((expires == null) ? "" : "; expires=" + expires.toGMTString()) +
  ((path == null) ? "" : "; path=" + path) +
  ((domain == null) ? "" : "; domain=" + domain) +
  ((secure == null) ? "" : "; secure");
}

// An adaptation of Dorcht's function for deleting a cookie.
function delCookie (name,path,domain) {
  if (getCookie(name)) {
    document.cookie = name + "=" +
    ((path == null) ? "" : "; path=" + path) +
    ((domain == null) ? "" : "; domain=" + domain) +
    "; expires=Thu, 01-Jan-70 00:00:01 GMT";
  }
}



if(window.event + "" == "undefined") event = null;
function HM_f_PopUp(){return false};
function HM_f_PopDown(){return false};
popUp = HM_f_PopUp;
popDown = HM_f_PopDown;


HM_PG_MenuWidth =165;
HM_PG_FontFamily = "Arial,sans-serif";
HM_PG_FontSize = 10;
HM_PG_FontBold = 1;
HM_PG_FontItalic = 0;
HM_PG_FontColor = "#66ff00";
HM_PG_FontColorOver = "#66ff00";
HM_PG_BGColor = "#66ff00";
HM_PG_BGColorOver = "#66ff00";
HM_PG_ItemPadding = 2;

HM_PG_BorderWidth = 1;
HM_PG_BorderColor = "black";
HM_PG_BorderStyle = "solid";
HM_PG_SeparatorSize = 1;
HM_PG_SeparatorColor = "#d0ff00";
HM_PG_ImageSrc = "/images/tri.gif";
HM_PG_ImageSrcLeft = "/images/triL.gif";

HM_PG_ImageSize = 4;
HM_PG_ImageHorizSpace = 0;
HM_PG_ImageVertSpace = 1;

HM_PG_KeepHilite = true; 
HM_PG_ClickStart = 0;
HM_PG_ClickKill = false;
HM_PG_ChildOverlap = 0;
HM_PG_ChildOffset = 5;
HM_PG_ChildPerCentOver = null;
HM_PG_TopSecondsVisible = .8;
HM_PG_StatusDisplayBuild =0;
HM_PG_StatusDisplayLink = 1;
HM_PG_UponDisplay = null;
HM_PG_UponHide = null;
HM_PG_RightToLeft = false;

//HM_PG_CreateTopOnly = 1;
HM_PG_ShowLinkCursor = 1;

//HM_a_TreesToBuild = [1,2];

var popWin = null    // use this when referring to pop-up window
var winCount = 0
var winName = "popWin"
function openPopWin(winURL, winWidth, winHeight, winFeatures){
  winName = "popWin" + winCount++ //unique name for each pop-up window
  closePopWin()           // close any previously opened pop-up window
  if (openPopWin.arguments.length == 4)  // any additional features?
    winFeatures = "," + winFeatures
  else
     winFeatures = ""
  popWin = window.open(winURL, winName, "width=" + winWidth
           + ",height=" + winHeight + winFeatures)
  }
function closePopWin(){    // close pop-up window if it is open
  if (navigator.appName != "Microsoft Internet Explorer"
      || parseInt(navigator.appVersion) >=4) //do not close if early IE
    if(popWin != null) if(!popWin.closed) popWin.close()
   }
   function test(swap)
{
parent.topframe.location=swap
}

function whichOne(swap){
	 if (document.summary.go_search.value=="" && swap=="update")
	   {alert("Please Enter An Article Number.");document.summary.article.focus();}	
	 else
	 	 if (document.summary.article.value=="" && swap!="new" && document.summary.go_search.value=="")
	   {alert("Please Select An Article.");document.summary.article.focus();}	
	 else
	 {  
	  document.summary.whichButton.value=swap;
	  document.summary.submit();
	  }
 }
 
 function whichOnep(swap){
	 if (document.summary.bldgno.value =="" && swap=="process")
	   {alert("Please Enter a Room.");document.summary.bldgno.focus();}	
	 else
	 if (document.summary.OrdRefx.value =="" && swap=="process")
	   {alert("Please Select A Project.");document.summary.OrdRefx.focus();}
	 else
	 if
	 (document.summary.bldgno.value.length < 2 && swap=="process") 
	  	{
		mesg = "You have entered " + document.summary.bldgno.value.length + " character(s)\n"
		mesg = mesg + "Valid entries are greater then 2 characters.\n"
		mesg = mesg + "Please verify your input and submit again."
		alert(mesg);
		document.summary.bldgno.focus();
		}	
	 else
	 {  
	  document.summary.whichButton.value=swap;
	  document.summary.submit();
	  }
 }	
 
 function whichOner(swap){
	 if (document.summary.bldgno.value =="" && swap=="process")
	   {alert("Please Enter a Room number.");document.summary.bldgno.focus();}	
	 
	  else if 
	 ( document.summary.locbrws.value == "" && swap=="process")
	  {alert("Please Enter the Room number.");document.summary.locbrws.focus();}	
	 if
	 (document.summary.bldgno.value.length < 2 && swap=="process") 
	  	{
		mesg = "You have entered " + document.summary.bldgno.value.length + " character(s)\n"
		mesg = mesg + "Valid entries are greater then 2 characters.\n"
		mesg = mesg + "Please verify your input and submit again."
		alert(mesg);
		document.summary.bldgno.focus();
		}	
	 else if 
	 ( document.forms[1].activity[1].checked == true && document.summary.tobldgno.value == "" && swap=="process")
	  {alert("Please Enter the Room number to move to.");document.summary.tobldgno.focus();}	
	 else if 
	 ( document.forms[1].activity[1].checked == true && document.summary.tolocbrws.value == "" && swap=="process")
	  {alert("Please Enter the Building to move to.");document.summary.tolocbrws.focus();}	 
	 else
	 {  
	  document.summary.whichButton.value=swap;
	  document.summary.submit();
	  }
 }	