<!--
 function toggleStateProvince()
    {
        selCountry = document.getElementById("ddlCountries");
        province = document.getElementById( "uProvince" );
        state = document.getElementById("ddlStates");
        //lblPhoneSample = document.getElementById("ctl00_ContentPlaceHolder1_Signup1_lblPhoneSample");
        lblState = document.getElementById("txtStates");
        lblZip = document.getElementById("txtZip");
        if( selCountry.options[selCountry.selectedIndex].value == "38" )
        {
         //   spReq.innerHTML = "*";
         //Shows the provice text box
            province.style.display = "inline";
            //hides the state drop down list
            ddlStates.style.display = "none";
            lblState.innerHTML = "Province:";
            lblZip.innerHTML = "Zip Code:";
             //Select No state
            state.selectedIndex = 0;
           //lblPhoneSample.innerHTML = "(e.g.: 555-555-5555)";
        } else if( selCountry.options[selCountry.selectedIndex].value == "USA" )
        {
            // spReq.innerHTML = "*";
            province.style.display = "none";
            state.style.display = "inline";
            lblState.innerHTML = "State:";
            lblZip.innerHTML = "Zip Code:";
            //lblPhoneSample.innerHTML = "(e.g.: 555-555-5555)";
          
        } else
        {
            //lblPhoneSample.innerHTML = "&nbsp;";
            lblState.innerHTML = "Province:";
            lblZip.innerHTML = "Postal Code:";
            province.style.display = "inline";
            state.style.display = "none";
            state.selectedIndex = 0;
        }
    }        

	function doProcessing() {
			document.getElementById('button').className = 'thide'; 
			document.getElementById('processing').className = 'tshow';
		//	document.form.submit();
		}
	function doprocessingsub() {
			document.getElementById('button').className = 'tshow'; 
			document.getElementById('processing').className = 'thide';
		//	document.form.submit();
		}
		
	function setAge(s)
	{
	    var child = s;
	    if(child == 1)
	    {
	       cAge35 = document.getElementById('rbAge35'); 
           cAge35.checked = "checked";		    
 	    }else if(child = 2)
	    {
	        cAge45 = document.getElementById('rbAge45'); 
	        cAge45.checked = "checked";		    
	    }
	
	}
	
	function fixAge(s)
	{
	   var age = s;
	    if(age == 18)
	    {
	        //document.getElementById('rbWithoutChild').checked = "checked"; 
	        //document.getElementById('rbType40').checked = "checked";
	    }else if(age == 35)
	    {
	        document.getElementById('rbWithChild').checked = "checked"; 
	    
	    } 
        
   	
	}

		
	function openPopupWindow(URLtoOpen) {
		bName = navigator.appName;
		bVer = parseInt(navigator.appVersion);
		if((bName == "Netscape" && bVer >= 3) || (bName == "Microsoft Internet Explorer" && bVer >= 4))
			br = "n3";
		else
			br = "n2";
		
		if(br == "n3") {
			newWindow=window.open(URLtoOpen, 'lilone','toolbar=yes,width=300,height=350,left=500,top=300,directories=0,status=0,scrollbars=1,resizable=yes,menubar=0,location=0,copyhistory=0');
		}
	}
	
	/**
	*
	* Closes any existing popups before opening a new one
	* Any new windows will always have focus and you won't "loose" any existing windows
	*
	* Takes url for content and height and width for size of new window
	*/ 
	function popup( URL, width, height )
	{
		try
		{
			popup_window.close();
		}
		catch(e)
		{
					
		}
		
		popup_window=window.open( URL,"_popover","status=no,location=no,menubar=no,toolbar=no,directories=no,resizable=yes,scrollbars=yes,width=430,height=500,screenX=100,screenY=100");	
		window.onerror = null;
}
function openSpec(URL, width, height )
{
	try
	{
		popup_window.close();
	}
	catch(e)
	{
				
	}
		
	popup_window=window.open( URL,"_popover","status=no,location=no,menubar=no,toolbar=no,directories=no,resizable=yes,scrollbars=yes,width=430,height=500,screenX=100,screenY=100");	
	window.onerror = null;
}

function parseNumeric(theField) {
	var i = 0;
	var returnString = '';
	var c = '';
	var charsToKeep = '0123456789';
	var s = theField.value;
	while (s.charAt(i) == '-1' || charsToKeep.indexOf(i) == -1)	 i++;
	for (i; i < s.length; i++) {
		c = s.charAt(i);
		if (charsToKeep.indexOf(c) >= 0) returnString += c;
	}
	theField.value = returnString;
	document.forms[0].WP.value = document.forms[0].phone1.value + document.forms[0].phone2.value + document.forms[0].phone3.value;
	focusNextElement(theField);
}

function focusNextElement(theField){

	// automatically tab to the next field
	var el = 0, f = theField.form;
	while (f.elements[el]) {
		if (f.elements[el++] == theField) break; //find current field
	}
	if ((theField.value.length == theField.maxLength) && f.elements[el]) {
		f.elements[el].focus();
		return false;
	}

	return true;

}
function nextElement(theField){

	// automatically tab to the next field
	var el = 0, f = theField.form;
	while (f.elements[el]) {
		if (f.elements[el++] == theField) break; //find current field
	}
	if (f.elements[el]) {
		f.elements[el].focus();
		return false;
	}

	return true;

}
//-->
