function openLinkInNewWindow(url) {
var aWinStatus = "location=0, toolbar=0, directories=0, status=0, menubar=0, scrollbars=1, resizable=1,top=0, left=0, width=" + self.screen.availWidth + ", height=" + self.screen.availHeight;
window.open (url, "NewWin", aWinStatus); }
var openwin;

function popupwin(url,myname,w,h,s,r)
{ settings='height='+h+',width='+w+',scrollbars='+s+',toolbar=no,location=no,status=no,menubar=no,resizable='+r+',dependent=no'
openwin=window.open(url,myname,settings); }

function openwin(url) { newWindow=window.open(url, 'nwin',config='scrollbars=yes,resizable=yes,toolbar=yes,location=yes,status=yes,menubar=yes,');
newWindow.focus(); }

function dbstatwin(BrURL,BrWidth,BrHeight){
dbWindow=window.open(BrURL,'dbwin',config='scrollbars=no,resizable=no,toolbar=no,location=no,status=no,menubar=no,width='+BrWidth+',height='+BrHeight)
dbWindow.focus(); }

function DisplayImage(picURL,picWidth,picHeight){
newWindow=window.open(picURL,'newWin','toolbar=no,width='+picWidth+',height='+picHeight)
newWindow.document.write('<html><head><title>View Image<\/title><\/head><body><div align="center"><a href="javascript:window.close();"><img src="'+picURL+'" border="0" alt="Click Image to Close"></a><\/div><\/body><\/html>')
newWindow.document.close()
newWindow.resizeBy(picWidth-newWindow.document.body.clientWidth,picHeight-newWindow.document.body.clientHeight)
newWindow.focus(); }

function DisplayHTML(BrURL,BrWidth,BrHeight){
newWindow=window.open(BrURL,'bwin',config='scrollbars=no,resizable=no,toolbar=no,location=no,status=no,menubar=no,width='+BrWidth+',height='+BrHeight)
newWindow.focus(); }

function DisplayHELP(BrURL,BrWidth,BrHeight){
newWindow=window.open(BrURL,'bwin',config='scrollbars=yes,resizable=yes,toolbar=no,location=no,status=no,menubar=no,width='+BrWidth+',height='+BrHeight)
newWindow.focus(); }

function emailwin(url) { emailwin=window.open(url, 'emailwin',config='scrollbars=no,resizable=no,toolbar=no,location=no,status=no,menubar=no,height=560,width=740');
emailwin.focus(); }

function pleaseWait() { if (document.layers) { document.hidepage.visibility = 'hidden'; }
else if (document.all) { document.all.hidepage.style.visibility = 'hidden'; }
else { document.getElementById("hidepage").style.visibility = 'hidden'; }}

function resetAllForms (windowOrLayer) {
  if (!windowOrLayer)
    windowOrLayer = window;
  if (document.forms.length>0){
  for (var f = 0; f < document.forms.length; f++)
        windowOrLayer.document.forms[f].reset();
  }
  if (document.layers){
    for (var l = 0; l < windowOrLayer.document.layers.length;l++ )
       resetAllForms(windowOrLayer.document.layers[l]);
  }
}

function rld() { document.location.reload() }

function closepopup() {
    if (!newWindow.closed)
        newWindow.close();
}

function DoSubmit() {
	document.MyForm.submit();
}

function OpenMeter(meter_page) {
	window.open(meter_page,"meter","width=640,height=530")
}
