function popupwebinfo(URL) 
{
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=550,height=540');");
}

function popuppanel(URL) 
{
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=800,height=540');");
}

function popupexport(URL) 
{
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=300,height=300');");
}

function openlink(link, win){
  if (win != null) win.document.getElementById('pagesrect').src = link; else
    window.location = link;
  return false;
}

function popupsize(width, height, URL) 
{
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width="+width+", height="+height+"');");
}

function gotoconfirm(msg, URL)
{
  if (confirm(msg))
  {
    openlink(URL);
  }
}

function gotopopupconfirm(width, height, msg, URL)
{
  if (confirm(msg))
  {
    day = new Date();
    id = day.getTime();
    eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width="+width+", height="+height+"');");
  }
}

function setfocus()
{
  document.getElementById('firstcontrol').focus(); 
}

function gotoconfirm(msg, URL)
{
  if (confirm(msg))
  {
    openlink(URL);
  }
}


function jumpto(name)
{  
  openlink('#'+name, null);
}

function popupgallery(URL, width, height) 
{
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=500,height=640');");
}

function warningbox()
{
  alert ("Click the link and try again");
}

