	var img = new Image();
	img.src = 'images/website/menuOnButton.jpg';
	var img2 = new Image();
	img2.src = 'images/website/submitOn.jpg';
	var Pre, Post;
	if (document.getElementById) 
		{Pre = 'document.getElementById("'; Post = '")';}
	else if (document.all) 
		{Pre= 'document.all.'; Post = '';}	
	function jobsChanger()
	    {
	    with(document.forms[0])
	        {
	        if(job.options[job.selectedIndex].value == '5' && otherJob.value == '')
	            {
	            eval(Pre + 'otherJobValidator2' + Post).style.display = 'none'; 
	            eval(Pre + 'otherJobValidator' + Post).style.display = 'block';
	            otherJob.focus();
	            }
	        else
	            {
	            eval(Pre + 'otherJobValidator2' + Post).style.display = 'none'; 
	            eval(Pre + 'otherJobValidator' + Post).style.display = 'none';    
	            if(job.options[job.selectedIndex].value != '5' )otherJob.value = '';
	            }
	        }
	    }
	    
	function heardChanger()
	    {
	    with(document.forms[0])
	        {
	        if(heardFrom.options[heardFrom.selectedIndex].value != '6' )otherHeard.value = '';
            eval(Pre + 'otherHeardValidator' + Post).style.display = 'none';    
	        eval(Pre + 'otherHeardValidator3' + Post).style.display = 'none';	        
	        if(heardFrom.options[heardFrom.selectedIndex].value == '6' && otherHeard.value == '')
	            {
	            eval(Pre + 'otherHeardValidator' + Post).style.display = 'block';
	            otherHeard.focus();
	            }
	        else if(heardFrom.options[heardFrom.selectedIndex].value != '6' && heardFrom.options[heardFrom.selectedIndex].value != '' && otherHeard.value != '')
	            {
	            eval(Pre + 'otherHeardValidator3' + Post).style.display = 'block';
	            heardFrom.focus();
	            }
	        }
	    }
	    
    function removeValidator(val, _x)
        {
        var selVal;
        with(document.forms[0])
            {   
            if (_x == 1)
                {
                eval(Pre + 'otherJobValidator2' + Post).style.display = 'none';
                selVal = job.options[job.selectedIndex].value;
                if(val != '' && selVal == '5')
                    eval(Pre + 'otherJobValidator' + Post).style.display = 'none';    
                else if(val == '' && selVal == '5')
                    eval(Pre + 'otherJobValidator' + Post).style.display = 'block';    
                else if(val != '' && selVal != '5')
                    eval(Pre + 'otherJobValidator2' + Post).style.display = 'block';                    
                }
            else
                {
                eval(Pre + 'otherHeardValidator' + Post).style.display = 'none';
	            eval(Pre + 'otherHeardValidator3' + Post).style.display = 'none';	                
                selVal = heardFrom.options[heardFrom.selectedIndex].value;
                if(val != '' && selVal == '6')
                    eval(Pre + 'otherHeardValidator' + Post).style.display = 'none';    
                else if(val == '' && selVal == '6')
                    eval(Pre + 'otherHeardValidator' + Post).style.display = 'block';    
                else if(val != '' && selVal != '6')
                    eval(Pre + 'otherHeardValidator3' + Post).style.display = 'block';                                        
                }        
            }    
        }	
        
    function tellForm()
        {
        if(eval(Pre + 'otherJobValidator' + Post).style.display == 'block' || eval(Pre + 'otherJobValidator2' + Post).style.display == 'block' || eval(Pre + 'otherHeardValidator' + Post).style.display == 'block' || eval(Pre + 'otherHeardValidator3' + Post).style.display == 'block' || eval(Pre + 'validateReferralLbl' + Post).style.display == 'block')
            return false;
        }
            
function validateReferral(x)
    {
    if(x!='')
        {
        xmlHttp = GetXmlHttpObject();
	    xmlHttp.onreadystatechange = function() 
		    { 
		    if (xmlHttp.readyState == 4 || xmlHttp.readyState == "complete")
		        {
		        if(xmlHttp.responseText!='VALID')
			        document.getElementById('validateReferralLbl').style.display='block';
			    }
		    }
        xmlHttp.open("GET", 'validateAffiliate.aspx?affiliateID='+ x + '&rnd=' + Math.random(), true);
        //xmlHttp.open("GET", 'newAccount.aspx?'+ x + '&rnd=' + Math.random(), true);
	    xmlHttp.send(null);		
        }    
    }             
    
      