//WARNING: THIS IS A COMPRESSED FILE AND SHOULD NOT BE EDITED!!!
function UpdateCityZipSt(city, state, zip, cityZipRec) {
if ((cityZipRec != 'NONE') && (cityZipRec != '')) {
city.value = cityZipRec.substring(0, (cityZipRec.indexOf('{')))
for (i = 0; i < state.length; i++) {
if (state.options[i].value == cityZipRec.substring((cityZipRec.indexOf('{')+1), cityZipRec.indexOf('}'))) {
state.options[i].selected = true;
break
}
}
state.value = cityZipRec.substring((cityZipRec.indexOf('{')+1), cityZipRec.indexOf('}'))
zip.value = cityZipRec.substring((cityZipRec.indexOf('}')+1))
}
}
var reCoABF = /\s*-?\s*C\/O ABF.*/i;
var reFirst37Chars = /.{0,37}/;
function setTerminalInfo(frm, strParameters, intIndex) {
var i = 0;
var str = "";
var arrParameters = strParameters.split("|");
if (arrParameters.length >= 6) {
var strStation = arrParameters[i++];
var strAirlineCode = arrParameters[i++];
var strAddress = arrParameters[i++];
var strActualCityLoc = arrParameters[i++];
var strActualStateLoc = arrParameters[i++];
var strTermZipCode = arrParameters[i++];
var strCoTerminal = "C/O ABF SERVICE CENTER - " + strAirlineCode + "/" + strStation;
if (frm.txtAcctNamePlus) {
if (frm.txtAcctNamePlus[intIndex]) { frm.txtAcctNamePlus[intIndex].value = strCoTerminal; }
else                               { frm.txtAcctNamePlus.value = strCoTerminal; }
}
else if (frm.txtAcctName) {
if (frm.txtAcctName[intIndex]) {
str = frm.txtAcctName[intIndex].value.replace(reCoABF, "");
if (str.length <= 27) {
str += (str.length == 0 ? "" : " - ") + strCoTerminal;
str = str.match(reFirst37Chars);
frm.txtAcctName[intIndex].value = str;
}
}
else {
str = frm.txtAcctName.value.replace(reCoABF, "");
if (str.length <= 27) {
str += (str.length == 0 ? "" : " - ") + strCoTerminal;
str = str.match(reFirst37Chars);
frm.txtAcctName.value = str;
}
}
}
if(frm.txtAcctAddr) {
if (frm.txtAcctAddr[intIndex]) { frm.txtAcctAddr[intIndex].value = strAddress; }
else                           { frm.txtAcctAddr.value = strAddress; }
}
if(frm.txtAcctCity) {
if (frm.txtAcctCity[intIndex]) { frm.txtAcctCity[intIndex].value = strActualCityLoc; }
else                           { frm.txtAcctCity.value = strActualCityLoc; }
}
else if (frm.txtOrigCity && intIndex == 0) { frm.txtOrigCity.value = strActualCityLoc; }
else if (frm.txtDestCity && intIndex == 1) { frm.txtDestCity.value = strActualCityLoc; }
else if (frm.txtCity)                      { frm.txtCity.value = strActualCityLoc; }
if(frm.cboAcctState) {
if (eval('document.getElementById("cboAcctState'+intIndex+'")')) { eval('document.getElementById("cboAcctState'+intIndex+'").value = strActualStateLoc'); }
else                                                             { frm.cboAcctState.value = strActualStateLoc; }
}
else if (eval('document.getElementById("cboState'+intIndex+'")')) { eval('document.getElementById("cboState'+intIndex+'").value = strActualStateLoc'); }
else if (frm.cboState)                                            { frm.cboState.value = strActualStateLoc; }
else if (frm.cboDestState)                                        { frm.cboDestState.value = strActualStateLoc; }
else if (frm.cboOrigState)                                        { frm.cboOrigState.value = strActualStateLoc; }
if(frm.txtAcctState) {
if (frm.txtAcctState[intIndex]) { frm.txtAcctState[intIndex].value = strActualStateLoc; }
else                            { frm.txtAcctState.value = strActualStateLoc; }
}
if(frm.txtAcctZip) {
if (frm.txtAcctZip[intIndex]) { frm.txtAcctZip[intIndex].value = strTermZipCode; }
else                          { frm.txtAcctZip.value = strTermZipCode; }
}
else if (frm.txtOrigZip && intIndex == 0) { frm.txtOrigZip.value = strTermZipCode; }
else if (frm.txtDestZip && intIndex == 1) { frm.txtDestZip.value = strTermZipCode; }
else if (frm.txtZipCode)                  { frm.txtZipCode.value = strTermZipCode; }
}
}
var arrStates = new Array()
var arrCountry = new Array()
var locationString = new String(self.location)
function objState(name, code, country)
{  this.name = name.toUpperCase()
this.code = code
this.country = country
}
function objCountry(name, code)
{  this.name = name.toUpperCase();
this.code = code;
}
function compareStates(a, b)
{  if (a.country < b.country) {return -1; }
if (a.country > b.country) {return 1; }
if (a.country == b.country) {
if (a.code < b.code) { return -1 }
if (a.code > b.code) { return 1 }
}
return 0;
}
function initStList() {
arrStates[0] = new objState('Alabama','AL','US')
arrStates[1] = new objState('Alaska','AK','US')
arrStates[2] = new objState('Arizona','AZ','US')
arrStates[3] = new objState('Arkansas','AR','US')
arrStates[4] = new objState('California','CA','US')
arrStates[5] = new objState('Colorado','CO','US')
arrStates[6] = new objState('Connecticut','CT','US')
arrStates[7] = new objState('Delaware','DE','US')
arrStates[8] = new objState('District of Columbia','DC','US')
arrStates[9] = new objState('Florida','FL','US')
arrStates[10] = new objState('Georgia','GA','US')
arrStates[11] = new objState('Guam','GU','US')
arrStates[12] = new objState('Hawaii','HI','US')
arrStates[13] = new objState('Idaho','ID','US')
arrStates[14] = new objState('Illinois','IL','US')
arrStates[15] = new objState('Indiana','IN','US')
arrStates[16] = new objState('Iowa','IA','US')
arrStates[17] = new objState('Kansas','KS','US')
arrStates[18] = new objState('Kentucky','KY','US')
arrStates[19] = new objState('Louisiana','LA','US')
arrStates[20] = new objState('Maine','ME','US')
arrStates[21] = new objState('Maryland','MD','US')
arrStates[22] = new objState('Massachusetts','MA','US')
arrStates[23] = new objState('Michigan','MI','US')
arrStates[24] = new objState('Minnesota','MN','US')
arrStates[25] = new objState('Mississippi','MS','US')
arrStates[26] = new objState('Missouri','MO','US')
arrStates[27] = new objState('Montana','MT','US')
arrStates[28] = new objState('Nebraska','NE','US')
arrStates[29] = new objState('Nevada','NV','US')
arrStates[30] = new objState('New Hampshire','NH','US')
arrStates[31] = new objState('New Jersey','NJ','US')
arrStates[32] = new objState('New Mexico','NM','US')
arrStates[33] = new objState('New York','NY','US')
arrStates[34] = new objState('North Carolina','NC','US')
arrStates[35] = new objState('North Dakota','ND','US')
arrStates[36] = new objState('N. Mariana Islands','MP','US')
arrStates[37] = new objState('Ohio','OH','US')
arrStates[38] = new objState('Oklahoma','OK','US')
arrStates[39] = new objState('Oregon','OR','US')
arrStates[40] = new objState('Pennsylvania','PA','US')
arrStates[41] = new objState('Puerto Rico','PR','US')
arrStates[42] = new objState('Rhode Island','RI','US')
arrStates[43] = new objState('South Carolina','SC','US')
arrStates[44] = new objState('South Dakota','SD','US')
arrStates[45] = new objState('Tennessee','TN','US')
arrStates[46] = new objState('Texas','TX','US')
arrStates[47] = new objState('Utah','UT','US')
arrStates[48] = new objState('Vermont','VT','US')
arrStates[49] = new objState('Virgin Islands','VI','US')
arrStates[50] = new objState('Virginia','VA','US')
arrStates[51] = new objState('Washington','WA','US')
arrStates[52] = new objState('West Virginia ','WV','US')
arrStates[53] = new objState('Wisconsin','WI','US')
arrStates[54] = new objState('Wyoming','WY','US')
arrStates[55] = new objState('Alberta','AB','CA')
arrStates[56] = new objState('British Columbia','BC','CA')
arrStates[57] = new objState('Manitoba','MB','CA')
arrStates[58] = new objState('New Brunswick','NB','CA')
arrStates[59] = new objState('Newfoundland','NL','CA')
arrStates[60] = new objState('Nova Scotia','NS','CA')
arrStates[61] = new objState('Northwest Territories','NT','CA')
arrStates[62] = new objState('Ontario','ON','CA')
arrStates[63] = new objState('Prince Edward Island','PE','CA')
arrStates[64] = new objState('Quebec','QC','CA')
arrStates[65] = new objState('Saskatchewan','SK','CA')
arrStates[66] = new objState('Yukon','YT','CA')
arrStates[67] = new objState('Aguascalientes','AG','MX')
arrStates[68] = new objState('Baja California','BJ','MX')
arrStates[69] = new objState('Baja California Sur','BS','MX')
arrStates[70] = new objState('Campeche','CP','MX')
arrStates[71] = new objState('Chiapas','CH','MX')
arrStates[72] = new objState('Chihuahua','CI','MX')
arrStates[73] = new objState('Colima','CL','MX')
arrStates[74] = new objState('Coahuila de Zaragoza','CU','MX')
arrStates[75] = new objState('Distrito Federal','DF','MX')
arrStates[76] = new objState('Durango','DG','MX')
arrStates[77] = new objState('Guanajuato','GJ','MX')
arrStates[78] = new objState('Guerrero','GR','MX')
arrStates[79] = new objState('Hidalgo','HG','MX')
arrStates[80] = new objState('Jalisco','JA','MX')
arrStates[81] = new objState('Mexico','EM','MX')
arrStates[82] = new objState('Michoacan de Ocampo','MH','MX')
arrStates[83] = new objState('Morelos','MR','MX')
arrStates[84] = new objState('Nayarit','NA','MX')
arrStates[85] = new objState('Nuevo Leon','NL','MX')
arrStates[86] = new objState('Oaxaca','OA','MX')
arrStates[87] = new objState('Puebla','PU','MX')
arrStates[88] = new objState('Queretaro de Arteaga','QA','MX')
arrStates[89] = new objState('Quintana Roo','QR','MX')
arrStates[90] = new objState('San Luis Potosi','SL','MX')
arrStates[91] = new objState('Sinaloa','SI','MX')
arrStates[92] = new objState('Sonora','SO','MX')
arrStates[93] = new objState('Tabasco','TA','MX')
arrStates[94] = new objState('Tamaulipas','TM','MX')
arrStates[95] = new objState('Tlaxcala','TL','MX')
arrStates[96] = new objState('Veracruz-Llave','VL','MX')
arrStates[97] = new objState('Yucatan','YC','MX')
arrStates[98] = new objState('Zacatecas','ZT','MX')
}
function getStName(code,cty)
{  for (var z = 0; z < arrStates.length; z++)
{  if ((arrStates[z].code == code)&&(arrStates[z].country == cty))
{  return arrStates[z].name  }
}
return '';
}
function getStIdx(code,cty,blnAddOne)
{  var x = 0
if (blnAddOne) { x++ }
for (var z = 0; z < arrStates.length; z++)
{  if (arrStates[z].country == cty)
{  if (arrStates[z].code == code) { return x  }
}
x++
}
return 0;
}
function getCtyName(code)
{  if (code == 'CA') { return 'Canada' }
if (code == 'MX') { return 'Mexico' }
if (code == 'US') { return 'United States' }
}
function getCtyIdx(cty)
{  var lastCty = ''
var x = 0
for (var z = 0; z < arrStates.length; z++)
{  if (arrStates[z].country != lastCty)
{  if (arrStates[z].country == cty)
{  return x }
lastCty = arrStates[z].country
x++
}
}
return 0;
}
function updateCtyList(strCountry, item)
{  for (var x = 0; x < item.length; x++)
{  if (item.options[x].value == strCountry)
{  item.options[x].selected = true;
x = item.length + 1;
}
}
}
function updateCheckBox(country,formName,seq)
{  if ((typeof(eval("document."+formName+".chkCustOpt"))) != "undefined")
{  if ((seq == "") || (!eval("document."+formName+".chkCustOpt["+seq+"]")))
{  if(country == "MX")
{  eval("document."+formName+".chkCustOpt.checked = false")
eval("document."+formName+".chkCustOpt.disabled = true")
}
else   //(country != "MX")
{  eval("document."+formName+".chkCustOpt.disabled = false")
eval("document."+formName+".chkCustOpt.checked = false")
}
}
else
{  if (seq < 2)
{  if(country == "MX")
{  eval("document."+formName+".chkCustOpt["+seq+"].checked = false")
eval("document."+formName+".chkCustOpt["+seq+"].disabled = true")
}
else   //(country != "MX")
{  eval("document."+formName+".chkCustOpt["+seq+"].disabled = false")
eval("document."+formName+".chkCustOpt["+seq+"].checked = false")
}
}
}
}
var oCUAF = document.getElementById("chkCUAF");
if (oCUAF) {
if(seq == 1) {
if (document.getElementById("trCUAF")) { document.getElementById("trCUAF").className = (country=='CA')?"visible":"hidden"; }
oCUAF.checked = (country=='CA')?true:false;
oCUAF.disabled = (country=='CA')?true:false;
}
}
var oCBMPF = document.getElementById("chkCBMPF");
if (oCBMPF) {
if(seq == 0) {
if (document.getElementById("trCBMPF")) { document.getElementById("trCBMPF").className = (country=='CA')?"visible":"hidden"; }
oCBMPF.checked = (country=='CA')?true:false;
oCBMPF.disabled = (country=='CA')?true:false;
}
}
}
function updateStateList(country,stSelect,item)
{  if (typeof(strFormDisplayed) != "undefined")
{  ShowHideStateList(country);
if(strFormDisplayed == "AltDisplay") {return;}
}
if (country != "OT")
{   var idx = 1;
var idxSet = 0;
item.options.length = 0;
if (country == 'CA') {item.options[0] = new Option("(Select Province)","");}
else {item.options[0] = new Option("(Select State)","");}
for (var x = 0; x < arrStates.length; x++)
{  if (arrStates[x].country == country)
{  item.options[idx] = new Option(arrStates[x].name,arrStates[x].code)
if (stSelect == arrStates[x].code) { idxSet = idx }
idx++
}
}
item.options[idxSet].selected = true
}
}
function ShowHideStateList(country)
{  document.getElementById("OrigDisplay").className = (country == 'OT') ? 'hidden' : 'visible';
document.getElementById("AltDisplay").className = (country == 'OT') ? 'visible': 'hidden';
}
function buildStateSelectOptions(strCountry, strSelectedState)
{  if (!arrStates[0]) {initStList();}
if (strCountry != 'US' && strCountry != 'CA' && strCountry != 'MX')
{  strCountry = 'US'; }
for (var z = 0; z < arrStates.length; z++)
{  if (arrStates[z].country == strCountry)
{  if (arrStates[z].code == strSelectedState)
{ document.write("<OPTION SELECTED VALUE='"+arrStates[z].code+"'>"+arrStates[z].name+"</OPTION>"); }
else
{ document.write("<OPTION VALUE='"+arrStates[z].code+"'>"+arrStates[z].name+"</OPTION>"); }
}
}
}
function buildStateList(seq, formName, lstStName, CountrySelect, stSelect, chkContact)
{  if (CountrySelect == '') {CountrySelect = 'US';}
if (seq == null)         {seq = '';}
if (chkContact == null) {chkContact = false;}
else {chkContact = (chkContact == "False") ? false : true;}
if (formName == "frmAddContact")
{  if (whatB == "Netscape" && whatV == 4)
{  document.write("<SELECT NAME=\"" + lstStName + "\" SIZE=\"1\" CLASS=\"frm\" ID=\"" + lstStName + seq + "\">") }
else {document.write("<SELECT style=\"width:180px;\" NAME=\"" + lstStName + "\" SIZE=\"1\" CLASS=\"frm\" ID=\"" + lstStName + seq + "\">") }
}
else
{  if(chkContact)
{  document.write("<SELECT NAME=\"" + lstStName + "\" SIZE=\"1\" ONCHANGE=\"checkContact(" + seq + ")\" CLASS=\"frm\" ID=\"" + lstStName + seq + "\">") }
else
{  document.write("<SELECT NAME=\"" + lstStName + "\" SIZE=\"1\" CLASS=\"frm\" ID=\"" + lstStName + seq + "\">") }
}
if (CountrySelect == 'CA') {document.write("<OPTION VALUE=''>(Select Province)</OPTION>");}
else                       {document.write("<OPTION VALUE=''>(Select State)</OPTION>");  }
for (var z = 0; z < arrStates.length; z++)
{   if (arrStates[z].country == CountrySelect)
{  if((locationString.indexOf('truckpack') > 0) && (seq == 0))
{  if (arrStates[z].code == stSelect)
{ document.write("<OPTION SELECTED VALUE='"+arrStates[z].code+"'>"+arrStates[z].name+"</OPTION>")  }
}
else
{  if (arrStates[z].code == stSelect)
{  document.write("<OPTION SELECTED VALUE='"+arrStates[z].code+"'>"+arrStates[z].name+"</OPTION>")  }
else
{  document.write("<OPTION VALUE='"+arrStates[z].code+"'>"+arrStates[z].name+"</OPTION>")  }
}
}
}
document.write("</SELECT>")
}
function populateStateDropDown(strFormName,strComboBoxName)
{  var strCountry = 'US'
if (document.getElementById(strComboBoxName))
{  var objStates = document.getElementById(strComboBoxName)
if (eval("document."+strFormName+".optRemoteCountry[0]"))
{  initCntryList()
for (var i=0;i<arrCountry.length;i++)
{  if (eval("document."+strFormName+".optRemoteCountry["+i+"]"))
{  if (eval("document."+strFormName+".optRemoteCountry["+i+"].checked"))
{  strCountry = arrCountry[i].code;
i = arrCountry.length;
}
}
}
}
updateStateList(strCountry,'',objStates);
}
}
function RadCountrySelected(strFormName,radFormNum)
{  if (eval('window.opener.document.' + strFormName + '.radAcctCountry' + radFormNum + '[0]').checked)       return "US";
else if (eval('window.opener.document.' + strFormName + '.radAcctCountry' + radFormNum + '[1]').checked)  return "CA";
else if (eval('window.opener.document.' + strFormName + '.radAcctCountry' + radFormNum + '[2]').checked)  return "MX";
else return "US";
}
function RadCountryIndexSelect(country)
{  if (country == "US")      return 0
else if (country == "CA") return 1
else if (country == "MX") return 2
else                      return 0
}
function buildRadioCountryList(seq,formName,lstCtyName,lstStName,CountrySelect,blnReqZip,blnShortForm,txtCustName,blnShowMexico,blnChkContact)
{  var lastCty = ''
var strSub = ''
if (seq == null) {seq = '';}
else {strSub = '['+seq+']';}
if (CountrySelect == "US")      {var checkUS = "CHECKED";}
else if (CountrySelect == "CA") {var checkCA = "CHECKED";}
else if (CountrySelect == "MX") {var checkMX = "CHECKED";}
else if (CountrySelect == "OT") {var checkOT = "CHECKED";}
else                            {var checkUS = "CHECKED";}
if (blnChkContact == null) {blnChkContact = false;}
else {blnChkContact = (blnChkContact == "False") ? false : true;}
document.write("<table BORDER='0' CELLPADDING='0' CELLSPACING='0' ><tr>")
if (blnChkContact)
{  document.write("<td NOWRAP><input type='radio' value='US' ONCLICK=\"updateStateList('US',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('US','"+formName+"','"+seq+"');checkContact('"+seq+"');ZipPostalText('US','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkUS+"></td>")  }
else
{  document.write("<td NOWRAP><input type='radio' value='US' ONCLICK=\"updateStateList('US',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('US','"+formName+"','"+seq+"');ZipPostalText('US','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkUS+"></td>")  }
document.write("<td NOWRAP><font CLASS='formTxt'>United States&nbsp;&nbsp;</font></td>")
if (blnChkContact)
{  document.write("<td><input type='radio' value='CA' ONCLICK=\"updateStateList('CA',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('CA','"+formName+"','"+seq+"');checkContact('"+seq+"');ZipPostalText('CA','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkCA+"></td>")  }
else
{  document.write("<td><input type='radio' value='CA' ONCLICK=\"updateStateList('CA',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('CA','"+formName+"','"+seq+"');ZipPostalText('CA','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkCA+"></td>")  }
document.write("<td NOWRAP><font CLASS='formTxt'>Canada&nbsp;&nbsp;</font></td>")
if (blnShowMexico != "False")
{  if (blnChkContact)
{  document.write("<td><input type='radio' value='MX' ONCLICK=\"updateStateList('MX',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('MX','"+formName+"','"+seq+"');checkContact('"+seq+"');ZipPostalText('MX','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkMX+"></td>")  }
else
{  document.write("<td><input type='radio' value='MX' ONCLICK=\"updateStateList('MX',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('MX','"+formName+"','"+seq+"');ZipPostalText('MX','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkMX+"></td>")  }
document.write("<td NOWRAP><font CLASS='formTxt'>Mexico&nbsp;&nbsp;</font></td>")
}
if (typeof blnShowRadCountryOT != "undefined")
{  if (blnChkContact)
{  document.write("<td><input type='radio' value='OT' ONCLICK=\"updateStateList('OT',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('OT','"+formName+"','"+seq+"');checkContact('"+seq+"');ZipPostalText('OT','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkOT+"></td>")  }
else
{  document.write("<td><input type='radio' value='OT' ONCLICK=\"updateStateList('OT',null,document." + formName + "." + lstStName + strSub + ");updateCheckBox('OT','"+formName+"','"+seq+"');ZipPostalText('OT','"+formName+"','"+seq+"','"+blnReqZip+"','"+blnShortForm+"','"+txtCustName+"');\" NAME=\"" + lstCtyName + seq + "\" ID=\"" + lstCtyName + seq + "\" CLASS=\"frm\" "+checkOT+"></td>")  }
document.write("<td NOWRAP><font CLASS='formTxt'>Other</font></td>")
}
document.write("</tr></table>")
}
function initCntryList()
{  arrCountry[0] = new objCountry('U.S.','US')
arrCountry[1] = new objCountry('Canada','CA')
arrCountry[2] = new objCountry('Mexico','MX')
arrCountry[3] = new objCountry('Other','OT')
}
function buildCountrySelectOptions(blnShowUS,blnShowCA,blnShowMX,blnShowOT,strSelectedCountry)
{  if (!arrCountry[0]) {initCntryList();}
if (strSelectedCountry != 'US' && strSelectedCountry != 'CA' && strSelectedCountry != 'MX' && strSelectedCountry != 'OT')
{  strSelectedCountry = 'US'; }
for (var z = 0; z < arrCountry.length; z++)
{  if (!((arrCountry[z].code == 'US' && !(blnShowUS)) || (arrCountry[z].code == 'CA' && !(blnShowCA)) || (arrCountry[z].code == 'MX' && !(blnShowMX)) || (arrCountry[z].code == 'OT' && !(blnShowOT))))
{  if (arrCountry[z].code == strSelectedCountry)
{  document.write("<OPTION SELECTED VALUE='"+arrCountry[z].code+"'>"+arrCountry[z].name+"</OPTION>");  }
else
{  document.write("<OPTION VALUE='"+arrCountry[z].code+"'>"+arrCountry[z].name+"</OPTION>"); }
}
}
}
function buildDropDownCountryList(seq, formName, lstCountryName, lstStName, CountrySelect, blnReqZip, blnShortForm, txtCustName, blnShowMexico, blnShowOT, bAbbrieviate)
{  if (!arrCountry[0]) {initCntryList()}
if (lstStName == null)     {lstStName = '';}
if (blnReqZip == null)     {blnReqZip = '';}
if (blnShortForm == null)  {blnShortForm = '';}
if (txtCustName == null)   {txtCustName = '';}
if (seq == null)           {seq = '';}
if (blnReqZip == null)     {blnReqZip = '';}
if (blnShowMexico == null) {blnShowMexico = true;}
if (blnShowOT == null)     {blnShowOT = true;}
if (bAbbrieviate == null)  {bAbbrieviate = false;}
var sSelectList = '<select name="'+lstCountryName+'" size=1 id="'+lstCountryName+seq+'" ';
if (lstStName != '')
{ sSelectList += 'onchange="updateStateList(this.value,null,document.'+formName+'.'+lstStName+seq+');updateCheckBox(this.value,\''+formName+'\',\''+seq+'\');ZipPostalText(this.value, \''+formName+'\', \''+seq+'\', \''+blnReqZip+'\', \''+blnShortForm+'\', \''+txtCustName+'\'); " name="'+lstCountryName+seq+'">'; }
else
{ sSelectList += 'onchange="InBondCheck('+seq+');updateCheckBox(this.value,\''+formName+'\',\''+seq+'\');">'; }
for (var z = 0; z < arrCountry.length; z++)
{  if (!((arrCountry[z].code == 'MX' && !(blnShowMexico)) || (arrCountry[z].code == 'OT' && !(blnShowOT))))
{  var sSelected = (arrCountry[z].code == CountrySelect) ? 'selected ' : '';
var sName = (bAbbrieviate) ? arrCountry[z].code : arrCountry[z].name;
sSelectList += '<option '+sSelected+'value="'+arrCountry[z].code+'">'+sName+'</option>';
}
}
sSelectList += '</select>';
document.write(sSelectList);
}
function ZipPostalText(Country, formName, seq, blnReqZip, blnShortForm, txtCustName)
{  var objDynTxt = eval("document."+formName+".txtZip")
if (objDynTxt)
{  if (!ns4)
{  var dynText
if ((typeof(eval("document."+formName+".dynState"))) != "undefined")
{  if (Country == 'CA')
{  eval("document."+formName+".dynState.value = 'Province*:'")  }
else
{  eval("document."+formName+".dynState.value = 'State*:'")  }
}
if ((Country == '') || (Country == 'US'))
{  if((formName == "frmLabels")||(formName == "frmBOL")||(formName == "fmPickup")||(formName == "fmQuickPickup")||(formName == "frmUserInfo")||(formName == "frmPasswordInfo")|| (formName == "frmPackingSlip") || (formName == "fmClaim"))
{ dynText = "City/State/Zip" }
else {dynText = "Zip Code";}
}
else
{  if((formName == "frmLabels")||(formName == "frmBOL")||(formName == "fmPickup")||(formName == "fmQuickPickup")||(formName == "frmUserInfo")||(formName == "frmPasswordInfo") || (formName == "frmPackingSlip") || (formName == "fmClaim"))
{ dynText = "City/State/Postal" }
else {dynText = "Postal Code";}
}
if (blnShortForm == 'True') {dynText = txtCustName+" "+dynText;}
if (blnReqZip=="True")      {dynText = dynText+"*";}
if ((seq == '') || (seq == null))
{  if (formName != "frmAddContact")
{ objDynTxt.value = dynText+":" }
}
if (document.getElementById('tdState'))
{  SetInnerText(document.getElementById('tdState'), ((Country == 'CA')? 'Province*':'State*')); }
else
{  if (objDynTxt[seq]) {objDynTxt[seq].value = dynText+":";}
else {objDynTxt.value = dynText+":"; }
InBondCheck(seq);
}
}
}
}
function InBondCheck(seq)
{  if ((seq < 2) && (window.ShowHideInBond))
{  ShowHideInBond(); }
}
initStList()