var s_account = "";
var s_company = ""



function initSiteCatalystAccount(accountId, company){
	s_account = accountId;
	s_company = company;
}



function initSiteCatalystTrackObj(server, pagetype, platform, site){
	s.server = server;
	s.pageType = pagetype;
	s.prop11 = site;
	s.prop12 = platform;
}



function setSiteCatalystTrackObj(
	countrycode, 
	languagecode, 
	modelcode, 
	channel, 
	page, 
	subpage, 
	action
){
	var localPart = s_company + "." + countrycode;
	var sitePath = s.prop11 + ":" + channel + ":" + page;

	if( subpage != "" ){
		sitePath = sitePath + ":" + subpage;
	}
	
	if( action != "" ){
		sitePath = sitePath + ":" + action;
	}
	
	s.pageName = localPart + ":" + sitePath;
	
	s.channel = localPart + ":" + s.prop11 + ":" + channel;
	s.prop1 = sitePath;
	s.prop6 = channel;
	s.prop13 = localPart;
	s.prop14 = languagecode;
	
	s.prop16 = s.channel + ":" + page;
	
	// Doku gilt nicht, Buerkle moechte 16 immer haben und zwar als channel + page
	/*s.prop16 = "";

	if( (page != "") && (subpage != "") ){
		s.prop16 = s.channel + ":" + page;
	}*/
	
	s.prop17 = "";
	
	// Moechte Buerkle zur Zeit nicht haben
	/*if( (subpage != "") && (action != "") ){
		s.prop17 = s.prop16 + ":" + subpage;
	}*/
	
	s.prop31 = modelcode;
	s.prop32 = localPart + ":" + modelcode;
	s.hier1 = s.pageName;
	s.hier2 = s.prop1.replace(/:/g, "|");
	
	/*alert(
		"server: " + s.server
		+ "\npagetype: " + s.pageType
		+ "\nplatform/prop12: " + s.prop12
		+ "\nsite/prop11: " + s.prop11
		+ "\npagename: " + s.pageName
		+ "\nchannel: " + s.channel
		+ "\nprop1: " + s.prop1
		+ "\nprop6: " + s.prop6
		+ "\nprop13: " + s.prop13
		+ "\nprop14: " + s.prop14
		+ "\nprop16: " + s.prop16
		+ "\nprop17: " + s.prop17
		+ "\nprop31: " + s.prop31
		+ "\nprop32: " + s.prop32
		+ "\nhier1: " + s.hier1
		+ "\nhier2: " + s.hier2
	);*/
}



function siteCatalystTrack(){
	var s_code = s.t();
	
	if( s_code ){
		document.write(s_code);
	}
	
	if( navigator.appVersion.indexOf('MSIE') >= 0 ){
		document.write(unescape('%3C') + '\!-' + '-');
	}
}