<!--CHRYSLER ANALYTICS SYSTEM (CAS) CODE VERSION 1.0 (Universal)-->

var jsFileInclude = "<script language='javascript1.1' src='cas.js'></script>";
var jsFile = "cas.js";
var domainName = "chryslercareers.com";


function setPageViewVariables(){   
  var path = location.pathname;
  var pathTokens = path.substring(1).split("/");
  var tokenCount = pathTokens.length -1;
  if (tokenCount > 10) tokenCount = 10;                                       
  var pathPageName = path;
  if (pathTokens[pathTokens.length - 1] == "") pathPageName += "index.html";
         
  if (typeof pv == 'undefined') pv = new Object();
  for (count = 0; count < tokenCount; count++) {
   pv['p.a_' + (count + 1)] = pathTokens[count];
  } 
  var pageCategory = category;  
  pv['p.a_10'] = pageCategory;
    
  if (typeof pageName != 'undefined') {
   // First check and see if we have a "pageName" variable set in the page
    pv['name'] = pageName;                                               
 } else if (typeof hbx.pn != 'undefined') {
   // If not, look for hbx.pn and set that and use hbx.mlc as the first attribute
   // (potentially overriding the first part of the path token set above)
   pv['name'] = hbx.pn;
   pv['p.a_10'] = hbx.mlc;
  } else {  
   // If none of the other options work, use the page name from the URL.
   pv['name'] = pathPageName;
  }
}

function getAccountNumber(){
	var acctNumber = "100581";         //Default to Dashboard Production 100581.	
	var tmp = location.hostname.split(".");   
	var env = tmp[0].toLowerCase();
	
	if (env.indexOf("stageproxydashboard") >= 0){
		acctNumber = "100582";     // Dashboard Test 100582
	}
	return acctNumber;
}

function getPageName(){
	if (pageName == ""){
		return "PUT+PAGE+NAME+HERE";
	}else{
		return pageName;
	}
}

function getCategory(){
	if (category == ""){
		return "CONTENT+CATEGORY"
	}else{
		return category;
	}
}

//BEGIN EDITABLE SECTION
//CONFIGURATION VARIABLES

dataset = getAccountNumber();		//ACCOUNT NUMBER
PageName = getPageName();		//PAGE NAME
setPageViewVariables();		//AASSIGN MULTI-LEVEL URL CATEGORIES TO ATTRIBUTES



//INSERT OTHER CUSTOM EVENTS

//END EDITABLE SECTION

<!--END CAS CODE-->



