/* [nodename, id, name, navigationtext, href, isnavigation, childs[], templatename] */

if (typeof(decodeURIComponent) == 'undefined') {
  decodeURIComponent = function(s) {
    return unescape(s);
  }
}

function jdecode(s) {
    s = s.replace(/\+/g, "%20")
    return decodeURIComponent(s);
}

var POS_NODENAME=0;
var POS_ID=1;
var POS_NAME=2;
var POS_NAVIGATIONTEXT=3;
var POS_HREF=4;
var POS_ISNAVIGATION=5;
var POS_CHILDS=6;
var POS_TEMPLATENAME=7;
var POS_TARGET=8;
var theSitetree=[ 
	['PAGE','201',jdecode('Home'),jdecode(''),'/201.html','true',[],'',''],
	['PAGE','82901',jdecode('Training+Sites'),jdecode(''),'/82901/index.html','true',[ 
		['PAGE','84001',jdecode('House+of+Iron+and+Stone'),jdecode(''),'/82901/84001.html','true',[],'',''],
		['PAGE','84022',jdecode('1-0-7+Barbell'),jdecode(''),'/82901/84022.html','true',[],'',''],
		['PAGE','84043',jdecode('Titans+of+Iron'),jdecode(''),'/82901/84043.html','true',[],'',''],
		['PAGE','85823',jdecode('Big+Al%26%23x27%3Bs+Dino+Gym'),jdecode(''),'/82901/85823.html','true',[],'',''],
		['PAGE','88923',jdecode('Belton+Hanger'),jdecode(''),'/82901/88923.html','true',[],'','']
	],'',''],
	['PAGE','207',jdecode('News+%2B+Events'),jdecode(''),'/207.html','true',[],'',''],
	['PAGE','212',jdecode('Athlete+Spotlight'),jdecode(''),'/212/index.html','true',[ 
		['PAGE','96623',jdecode('Rodney+Wood'),jdecode(''),'/212/96623.html','true',[],'',''],
		['PAGE','92023',jdecode('Zack+Best'),jdecode(''),'/212/92023.html','true',[],'',''],
		['PAGE','70001',jdecode('Tyler+Schuman'),jdecode(''),'/212/70001.html','true',[],'',''],
		['PAGE','70022',jdecode('Josh+Aguilar'),jdecode(''),'/212/70022.html','true',[],'',''],
		['PAGE','67901',jdecode('KCSTRONGMAN'),jdecode(''),'/212/67901.html','true',[],'',''],
		['PAGE','64601',jdecode('John+Connor'),jdecode(''),'/212/64601.html','true',[],'',''],
		['PAGE','58101',jdecode('Justin+Wheeler-NAS+Champ'),jdecode(''),'/212/58101.html','true',[],'',''],
		['PAGE','56901',jdecode('Eric+Rothwell-NAS+Champ'),jdecode(''),'/212/56901.html','true',[],'',''],
		['PAGE','47601',jdecode('Mark+Reinig-NAS+Champ'),jdecode(''),'/212/47601.html','true',[],'',''],
		['PAGE','217',jdecode('Kevin+McNease'),jdecode(''),'/212/217.html','true',[],'',''],
		['PAGE','222',jdecode('Archives'),jdecode(''),'/212/222.html','true',[],'','']
	],'',''],
	['PAGE','227',jdecode('Photos'),jdecode(''),'/227.html','true',[],'',''],
	['PAGE','232',jdecode('Community'),jdecode(''),'/232/index.html','true',[ 
		['PAGE','237',jdecode('Forum'),jdecode(''),'/232/237.html','true',[],'',''],
		['PAGE','247',jdecode('Links+of+Interest'),jdecode(''),'/232/247.html','true',[],'',''],
		['PAGE','74722',jdecode('KCSTRONGMAN+Pros'),jdecode(''),'/232/74722.html','true',[],'',''],
		['PAGE','74701',jdecode('National+Champs'),jdecode(''),'/232/74701.html','true',[],'',''],
		['PAGE','74743',jdecode('All-Americans'),jdecode(''),'/232/74743.html','true',[],'',''],
		['PAGE','43301',jdecode('Strongman+Website'),jdecode(''),'/232/43301.html','true',[],'',''],
		['PAGE','43322',jdecode('Competitor+websites'),jdecode(''),'/232/43322.html','true',[],'',''],
		['PAGE','252',jdecode('KC+Strongmen'),jdecode(''),'/232/252.html','true',[],'',''],
		['PAGE','257',jdecode('Join+The+Insane'),jdecode(''),'/232/257.html','true',[],'','']
	],'',''],
	['PAGE','6101',jdecode('Supporters'),jdecode(''),'/6101.html','true',[],'',''],
	['PAGE','262',jdecode('Contact+Us'),jdecode(''),'/262/index.html','true',[ 
		['PAGE','5402',jdecode('Contact+Us+%28follow+up+page%29'),jdecode(''),'/262/5402.html','false',[],'','']
	],'',''],
	['PAGE','9506',jdecode('Guestbook'),jdecode(''),'/9506/index.html','true',[ 
		['PAGE','9501',jdecode('Read+Guestbook'),jdecode(''),'/9506/9501.html','false',[],'','']
	],'',''],
	['PAGE','19201',jdecode('Fallen+Warrior'),jdecode(''),'/19201.html','true',[],'',''],
	['PAGE','21801',jdecode('Contests'),jdecode(''),'/21801/index.html','true',[ 
		['PAGE','50301',jdecode('MO+Strongest%2FGus+Lohman+VII'),jdecode(''),'/21801/50301.html','true',[],'',''],
		['PAGE','62601',jdecode('KC+Challenge'),jdecode(''),'/21801/62601.html','true',[],'','']
	],'',''],
	['PAGE','37701',jdecode('Media'),jdecode(''),'/37701.html','true',[],'','']];
var siteelementCount=41;
theSitetree.topTemplateName='Architekt';
theSitetree.paletteFamily='8CBBD8';
theSitetree.keyvisualId='1703';
theSitetree.keyvisualName='gewichtheben.jpg';
theSitetree.fontsetId='282';
theSitetree.graphicsetId='348';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='8CBBD8';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Architekt',
				paletteFamily: 	'8CBBD8',
				keyvisualId: 	'1703',
				keyvisualName: 	'gewichtheben.jpg',
				fontsetId: 		'282',
				graphicsetId: 	'348',
				contentColor: 	'000000',
				contentBGColor: '8CBBD8',
				a_color: 		'8CBBD8',
				b_color: 		'338299',
				c_color: 		'FFFFFF',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'true',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '70001',
internalId:  '',
customField: '20090911-082336'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '70022',
internalId:  '',
customField: '20090828-093358'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '201',
internalId:  '1006',
customField: '1006'
};
webappMappings['1002']=webappMappings['1002-9506aen010in21yg']={
webappId:    '1002',
documentId:  '9506',
internalId:  '9506aen010in21yg',
customField: 'icq=false'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '201',
internalId:  '',
customField: '20091009-121202'
};
webappMappings['1501']=webappMappings['1501-3591410']={
webappId:    '1501',
documentId:  '201',
internalId:  '3591410',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '207',
internalId:  '',
customField: '20091005-084311'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '212',
internalId:  '',
customField: '20060315-095213'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '64601',
internalId:  '',
customField: '20080909-102715'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '58101',
internalId:  '',
customField: '20080107-113410'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '56901',
internalId:  '',
customField: '20080107-115053'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '47601',
internalId:  '',
customField: '20070927-071214'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '217',
internalId:  '',
customField: '20070926-065526'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '222',
internalId:  '',
customField: '20070926-065629'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '227',
internalId:  '',
customField: '20070910-084556'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '232',
internalId:  '',
customField: '20070809-082444'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '237',
internalId:  '',
customField: '20050907-223600'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '82901',
internalId:  '',
customField: '20091027-073401'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '247',
internalId:  '',
customField: '20071018-115645'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43301',
internalId:  '',
customField: '20090918-093050'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43322',
internalId:  '',
customField: '20071018-114539'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '252',
internalId:  '',
customField: '20070809-084231'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '257',
internalId:  '',
customField: '20060315-100606'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6101',
internalId:  '',
customField: '20091026-094238'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '262',
internalId:  '',
customField: '20050829-204114'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5402',
internalId:  '',
customField: '20050829-205537'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9506',
internalId:  '',
customField: '20070910-084136'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9501',
internalId:  '',
customField: '20060217-101033'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19201',
internalId:  '',
customField: '20070326-055957'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '21801',
internalId:  '',
customField: '20090904-112523'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '50301',
internalId:  '',
customField: '20091104-082302'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '62601',
internalId:  '',
customField: '20080327-074330'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '37701',
internalId:  '',
customField: '20080812-105617'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '96623',
internalId:  '',
customField: '20091104-084216'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '67901',
internalId:  '',
customField: '20090320-101349'
};
webappMappings['7008']=webappMappings['7008-2213']={
webappId:    '7008',
documentId:  '262',
internalId:  '2213',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '74722',
internalId:  '',
customField: '20090922-082151'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '74701',
internalId:  '',
customField: '20090925-092740'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '74743',
internalId:  '',
customField: '20091112-084002'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '84001',
internalId:  '',
customField: '20091027-073946'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '84022',
internalId:  '',
customField: '20090925-083632'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '84043',
internalId:  '',
customField: '20090925-083024'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '85823',
internalId:  '',
customField: '20090925-095357'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '88923',
internalId:  '',
customField: '20090929-091612'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '92023',
internalId:  '',
customField: '20091019-083536'
};
var canonHostname = 'wscwrk01.ehost-services.com';
var accountId     = 'AEN010IN21YG';
var companyName   = 'KCStrongman.com';
var htmlTitle	  = 'KCSTRONGMAN%3A+Kansas+City+Strength+Sports';
var metaKeywords  = 'KCStrongman%2C+Eric+Todd%2C+Kansas+City+Strength+Sports+and+Events%2C+powerlifting%2C+highland+games%2C+weightlifting%2C+strength%2C+power%2C+strongman%2C+bad+ass';
var metaContents  = 'KCStrongman%2C+Eric+Todd%2C+Kansas+City+Strength+Sports+and+Events';
theSitetree.getById = function(id, ar) {
	if (typeof(ar) == 'undefined'){
		ar = this;
	}
	for (var i=0; i < ar.length; i++) {
		if (ar[i][POS_ID] == id){
			return ar[i];
		}
		if (ar[i][POS_CHILDS].length > 0) {
			var result=this.getById(id, ar[i][POS_CHILDS]);
			if (result != null){
				return result;
			}
		}
	}
	return null;
};

theSitetree.getParentById = function(id, ar) {
	if (typeof(ar) == 'undefined'){
		ar = this;
	}
	for (var i=0; i < ar.length; i++) {
		for (var j = 0; j < ar[i][POS_CHILDS].length; j++) {
			if (ar[i][POS_CHILDS][j][POS_ID] == id) {
				// child found
				return ar[i];
			}
			var result=this.getParentById(id, ar[i][POS_CHILDS]);
			if (result != null){
				return result;
			}
		}
	}
	return null;
};

theSitetree.getName = function(id) {
	var elem = this.getById(id);
	if (elem != null){
		return elem[POS_NAME];
	}
	return null;
};

theSitetree.getNavigationText = function(id) {
	var elem = this.getById(id);
	if (elem != null){
		return elem[POS_NAVIGATIONTEXT];
	}
	return null;
};

theSitetree.getHREF = function(id) {
	var elem = this.getById(id);
	if (elem != null){
		return elem[POS_HREF];
	}
	return null;
};

theSitetree.getIsNavigation = function(id) {
	var elem = this.getById(id);
	if (elem != null){
		return elem[POS_ISNAVIGATION];
	}
	return null;
};

theSitetree.getTemplateName = function(id, lastTemplateName, ar) {
	if (typeof(lastTemplateName) == 'undefined'){
		lastTemplateName = this.topTemplateName;
	}
	if (typeof(ar) == 'undefined'){
		ar = this;
	}
	for (var i=0; i < ar.length; i++) {
		var actTemplateName = ar[i][POS_TEMPLATENAME];
		if (actTemplateName == ''){
			actTemplateName = lastTemplateName;
		}
		if (ar[i][POS_ID] == id) {
			return actTemplateName;
		}
		if (ar[i][POS_CHILDS].length > 0) {
			var result=this.getTemplateName(id, actTemplateName, ar[i][POS_CHILDS]);
			if (result != null){
				return result;
			}
		}
	}
	return null;
};

theSitetree.getByXx = function(lookup, xx, ar) {
    if (typeof(ar) == 'undefined'){
    	ar = this;
    }
    for (var i=0; i < ar.length; i++) {
        if (ar[i][xx] == lookup){
        	return ar[i];
        }
        if (ar[i][POS_CHILDS].length > 0) {
        	var result=this.getByXx(lookup, xx, ar[i][POS_CHILDS]);
            if (result != null){
                return result;
               }
        }
    }
    return null;
};

function gotoPage(lookup) {
	if(__path_prefix__ == "/servlet/CMServeRES" && typeof (changePage) == 'function'){
		changePage(lookup);
		return;
	}
	var page = theSitetree.getHREF(lookup);
	if (!page) {
		var testFor = [ POS_NAME, POS_NAVIGATIONTEXT ];
		for (var i=0 ; i < testFor.length ; i++) {
			var p = theSitetree.getByXx(lookup, testFor[i]);
			if (p != null) {
				page = p[POS_HREF];
				break;
			}
		}
	}
	document.location.href = (new URL(__path_prefix__ + page, true, true)).toString();
};
