function WindowPopup( Name, Parameters )
{
	window.open( Name, "popup", Parameters );
}

function winopen(o1,o2,o3,o4,o5,o6,o7,o8,o9,o10,o11,o12,o13,o14,o15,o16,o17,o18)
{
	var url = "";
	for( var k = 3; k <= 18; k++ )
	{
		if( eval("o"+k) ){
		    url = url + eval("o"+k);
		}
	}
	window.open( url, eval("o"+1), eval("o"+2) );
}
function buildButton(sURL, sCaption, eButtonColor, eButtonType, sFormName, sButtonName, bHiddenAfterClick)
{
  var sURLToUse;
  switch(eButtonType)
  {
    case 0:
      sURLToUse="javascript:window.close();";
      break;
    case 2:
      sURLToUse="javascript:window.print();";
      break;
    case 3:
      sURLToUse="javascript:buttonResetFn(\""+sFormName+"\", \""+sButtonName+"\");";
      break;
    case 4:
      sURLToUse="javascript:buttonSubmitFn(\""+sFormName+"\", \""+sButtonName+"\");";
      break;
    case 1:
    default:
      var sURLToUse=sURL;
      break;
  }
  switch(eButtonColor)
  {
    case 1:
      sHoldColor1="#c3c3c3";
      sHoldColor2="#686868";
      break;
    case 0:
    default:
      sHoldColor1="#FF0000";
      sHoldColor2="#990000";
      break;
  }
  document.write("<TABLE BORDER='0' CELLPADDING='0' CELLSPACING='0'>");
  document.write("<TR><TD BGCOLOR='#000000' ALIGN='center' COLSPAN='3'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' ALT='' BORDER='0'/></TD></TR>");
  document.write("<TR><TD BGCOLOR='#000000' ALIGN='center' WIDTH='1'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' WIDTH='1' ALT='' BORDER='0'/></TD>");
  document.write("<TD BGCOLOR='#686868' ALIGN='center'>");
  document.write("<TABLE BORDER='0' CELLPADDING='0' CELLSPACING='0'>");
  document.write("<TR><TD BGCOLOR='#686868' ALIGN='center'>");
  document.write("<TABLE BORDER='0' CELLPADDING='0' CELLSPACING='0'>");
  document.write("<TR><TD BGCOLOR='"+sHoldColor1+"' ALIGN='center' COLSPAN='3'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' ALT='' BORDER='0' />");
  document.write("</TD></TR>");
  document.write("<TR><TD BGCOLOR='"+sHoldColor1+"' ALIGN='center' WIDTH='1'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' WIDTH='1' ALT='' BORDER='0'/></TD>");
  document.write("<TD BGCOLOR='#686868' ALIGN='center'>");
  document.write("<TABLE BORDER='0' CELLPADDING='0' CELLSPACING='0'>");
  if(bHiddenAfterClick==1)
  {
    document.write("<TR><TD BGCOLOR='"+sHoldColor2);
    document.write("' ALIGN='center'  "," onClick=this.style.visibility='hidden'; >");
  }
  else
    document.write("<TR><TD BGCOLOR='"+sHoldColor2+"' ALIGN='center'>");
  document.write("<B>&nbsp;&nbsp;<A HREF='"+sURLToUse+"' CLASS='button'>");
  document.write("<FONT FACE='Verdana, Arial, Helvetica, Sans-Serif' COLOR='#FFFFFF' SIZE='-1'>");
  document.write("<SPAN CLASS='buttonhover'>");
  document.write(sCaption+"</SPAN></FONT></A>&nbsp;&nbsp;</B>");
  document.write("</TD></TR></TABLE></TD>");
  document.write("<TD BGCOLOR='#000000' ALIGN='center' WIDTH='1'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' WIDTH='1' ALT='' BORDER='0'/></TD></TR>");
  document.write("<TR><TD BGCOLOR='",sHoldColor1,"' ALIGN='center' WIDTH='1'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' ALT='' BORDER='0'/></TD>");
  document.write("<TD BGCOLOR='#000000' ALIGN='center' COLSPAN='2'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' ALT='' BORDER='0' />");
  document.write("</TD></TR></TABLE> </TD></TR></TABLE></TD>");
  document.write("<TD BGCOLOR='#000000' ALIGN='center' WIDTH='1'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' WIDTH='1' ALT='' BORDER='0'/>");
  document.write("</TD></TR><TR>");
  document.write("<TD BGCOLOR='#000000' ALIGN='center' COLSPAN='3'>");
  document.write("<IMG SRC='/images/world/s/spacer.gif' ALT='' BORDER='0'/>");
  document.write("</TD></TR></TABLE>");
  document.write("<INPUT type='hidden' value='0' name='");
  document.write(sButtonName);
  document.write("'>");
}
