function readCookie(name) 
{
	var nameEQ = name + "=";
	var ca = document.cookie.split(';');
	for(var i=0;i < ca.length;i++) {
		var c = ca[i];
		while (c.charAt(0)==' ') c = c.substring(1,c.length);
		if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
	}
	return null;
}

function choicePhone()
{
	switch(readCookie('phonetracking'))
	{
		case "ppc":
			return '<img src="http://www.spsboca.com/images/topheader_ppc.gif" width="980" height="69" border="0" usemap="#logolink" />';			
			break;
		case "organic":
			return '<img src="http://www.spsboca.com/images/topheader.gif" width="980" height="69" border="0" usemap="#logolink" />';			
			break;
		case "default":
		    return '<img src="http://www.spsboca.com/images/topheader.gif" width="980" height="69" border="0" usemap="#logolink" />';			
			break;
		default:
			return '<img src="http://www.spsboca.com/images/topheader.gif" width="980" height="69" border="0" usemap="#logolink" />';			
	}
}

function showPhoneHeader()
{
	document.write(choicePhone());
}
