var Server;

if((window.location.hostname == 'qalogin.ten-net.net') || (window.location.hostname == 'simportalqa01.ten-net.net')) 
{
//qa  
	Server ={
					Portal: 'http://simportalqa01.ten-net.net:8143',
					Career: 'http://www.countrywidecareers.com',
					AboutUS: 'http://stgabout.countrywide.com',
					HomeLoans: 'http://qacountrywide.ten-net.net',
	 				HomeLoansNew: 'http://homeloans.countrywide.com',
					FullSpectrum: 'http://www.fullspectrumlending.com',
					Bank: 'https://qa1bank.ten-net.net',
					Insurance: 'http://inscwqa.ten-net.net',
					EPass: 'http://qalogin.ten-net.net',
					Cyber: 'http://www3.cybertrust.com',
					RSA: 'http://www.rsasecurity.com/'
				};
} 
else if((window.location.hostname == 'unitsso.ten-net.net') || (window.location.hostname == 'simportaldev01.ten-net.net'))
{
	//dev 
	Server ={
					Portal: 'http://simportaldev01:8143',
					Career: 'http://www.countrywidecareers.com',
					AboutUS: 'http://stgabout.countrywide.com',
					HomeLoans: 'http://b2cdev.ten-net.net',
					HomeLoansNew: 'http://homeloans.countrywide.com',
					FullSpectrum: 'http://www.fullspectrumlending.com',
					Bank: 'http://devbank.ten-net.net',
					Insurance: 'http://inscwdv.ten-net.net',
					EPass: 'http://unitlogin.ten-net.net',
					Cyber: 'http://www3.cybertrust.com',
					RSA: 'http://www.rsasecurity.com/'
				};
}

else if ((window.location.hostname == 'stglogin.countrywide.com') || (window.location.hostname == 'stgmy.countrywide.com'))
{
	//stg
	Server ={
					Portal: 'http://stgmy.countrywide.com',
					Career: 'http://www.countrywidecareers.com',
					AboutUS: 'http://stgabout.countrywide.com',
					HomeLoans: 'http://staging.countrywide.com',
					HomeLoansNew: 'http://homeloans.countrywide.com',
					FullSpectrum: 'http://www.fullspectrumlending.com/default.asp',
					Bank: 'https://stgbank.countrywide.com/Default.aspx',
					Insurance: 'http://stginsurance.countrywide.com',
					EPass: 'https://stglogin.countrywide.com',
					Cyber: 'http://www3.cybertrust.com',
					RSA: 'http://www.rsasecurity.com/'
				};
}else 
{
	//prd
	Server ={
					Portal: 'http://my.countrywide.com',
					Career: 'http://www.countrywidecareers.com',
					AboutUS: 'http://about.countrywide.com',
					HomeLoans: 'http://www.countrywide.com',
					HomeLoansNew: 'http://homeloans.countrywide.com',
					FullSpectrum: 'http://www.fullspectrumlending.com',
					Bank: 'https://bank.countrywide.com',
					Insurance: 'http://insurance.countrywide.com',
					EPass: 'https://login.countrywide.com',
					Cyber: 'http://www3.cybertrust.com',
					RSA: 'http://www.rsasecurity.com/'
				};
}
		
function getURL( serverURL , pageURL  )
{
//sets the href of the <A href".." that it is called in
//<a href="javascript:getURL('Portal','/enrolleducation.aspx');">test</a>

	var returnVal = Server[ serverURL ] + pageURL;
	location.href = returnVal;
}
				
function getURL2( serverURL , pageURL  )
{
//returns the value as text
	var returnVal = Server[ serverURL ] + pageURL;
	return returnVal;
}



