function popup(URL,width,height) {

  // determine defaults for unspecified arguments
  if (!popup.arguments[1]) {
    width = 275;
  }
  if (!popup.arguments[2]) {
    height = 350;
  }

  // open a popup window and center it on the screen
  var handle    = null;
  var scrx      = (screen.width - width)/2;
  var scry      = (screen.height - height)/2;

  var winoptions = "height=" + height + ",width=" + width;

  // Windows Explorer
  if (navigator.appName.indexOf("Explorer") >= 0) {
    winoptions    += ",left=" + scrx + ",top=" + scry;
  } else {
    winoptions    += ",screenX=" + scrx + ",screenY=" + scry;
  }

  winhandle = window.open(URL,"popup",winoptions);

}

// delay closing of window
function delayclose(millisecs) {
  timer=setTimeout("window.close()",millisecs);
}
