function openBrWindow(theURL,winName,features) {window.open(theURL,winName,features);}

function vis(i) {document.getElementById('popup'+i).style.visibility = 'visible';}
function gem(i) {document.getElementById('popup'+i).style.visibility = 'hidden';}

var win = null;
function newWindow(mypage,myname,w,h,features) 
{
  var winl = 15;
  var wint = 15;
  if (winl < 0) winl = 0;
  if (wint < 0) wint = 0;
  var settings = 'height=' + h + ',';
  settings += 'width=' + w + ',';
  settings += 'top=' + wint + ',';
  settings += 'left=' + winl + ',';
  settings += features;
  win = window.open(mypage,myname,settings);
  win.window.focus();
}
