/* [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','31901',jdecode('Home'),jdecode(''),'/31901.html','true',[],'',''],
	['PAGE','801',jdecode('What%26%23x27%3Bs+New'),jdecode(''),'/801.html','true',[],'',''],
	['PAGE','54901',jdecode('Kokoda+Trek'),jdecode(''),'/54901.html','true',[],'',''],
	['PAGE','50801',jdecode('RYDGES+-+Capital+Hill+Health+Club'),jdecode(''),'/50801/index.html','true',[ 
		['PAGE','51101',jdecode('Monthly+News+Letter'),jdecode(''),'/50801/51101.html','true',[],'',''],
		['PAGE','51122',jdecode('What%26%23x27%3Bs+On'),jdecode(''),'/50801/51122.html','true',[],'',''],
		['PAGE','51143',jdecode('Fitness+Offers'),jdecode(''),'/50801/51143.html','true',[],'','']
	],'',''],
	['PAGE','33101',jdecode('Personal+Training'),jdecode(''),'/33101.html','true',[],'',''],
	['PAGE','49101',jdecode('Group+Fitness'),jdecode(''),'/49101.html','true',[],'',''],
	['PAGE','33301',jdecode('Corporate+Fitness'),jdecode(''),'/33301.html','true',[],'',''],
	['PAGE','34601',jdecode('Triathlon'),jdecode(''),'/34601/index.html','true',[ 
		['PAGE','48201',jdecode('Indoor+Ride-Run+Session'),jdecode(''),'/34601/48201.html','true',[],'',''],
		['PAGE','48601',jdecode('Swim+Squad'),jdecode(''),'/34601/48601.html','true',[],'','']
	],'',''],
	['PAGE','42901',jdecode('Swimming'),jdecode(''),'/42901/index.html','true',[ 
		['PAGE','49122',jdecode('Adult+Learn+to+Swim'),jdecode(''),'/42901/49122.html','true',[],'','']
	],'',''],
	['PAGE','45101',jdecode('Running'),jdecode(''),'/45101.html','true',[],'',''],
	['PAGE','852',jdecode('Training+Sessions+'),jdecode(''),'/852.html','true',[],'',''],
	['PAGE','26322',jdecode('Altitude+Training'),jdecode(''),'/26322/index.html','true',[ 
		['PAGE','29522',jdecode('Sports+Performance'),jdecode(''),'/26322/29522.html','true',[],'',''],
		['PAGE','29543',jdecode('Rehabilitation'),jdecode(''),'/26322/29543.html','true',[],'',''],
		['PAGE','29564',jdecode('Pre-Acclimatise'),jdecode(''),'/26322/29564.html','true',[],'',''],
		['PAGE','29585',jdecode('Weight+Loss+-+Health+and+Wellbeing'),jdecode(''),'/26322/29585.html','true',[],'','']
	],'',''],
	['PAGE','26301',jdecode('Blood+Lactate+Testing'),jdecode(''),'/26301.html','true',[],'',''],
	['PAGE','41401',jdecode('Articles'),jdecode(''),'/41401.html','true',[],'',''],
	['PAGE','41422',jdecode('Sponsors'),jdecode(''),'/41422.html','true',[],'',''],
	['PAGE','41443',jdecode('Partners'),jdecode(''),'/41443.html','true',[],'',''],
	['PAGE','44201',jdecode('Clothing'),jdecode(''),'/44201.html','true',[],'',''],
	['PAGE','29711',jdecode('For+Sale'),jdecode(''),'/29711.html','true',[],'',''],
	['PAGE','873',jdecode('Contact'),jdecode(''),'/873.html','true',[],'',''],
	['PAGE','41101',jdecode('Links'),jdecode(''),'/41101.html','true',[],'',''],
	['PAGE','29669',jdecode('Search'),jdecode(''),'/29669.html','true',[],'','']];
var siteelementCount=31;
theSitetree.topTemplateName='Office';
theSitetree.paletteFamily='727D9C';
theSitetree.keyvisualId='11165';
theSitetree.keyvisualName='kv_11165.jpg';
theSitetree.fontsetId='32065';
theSitetree.graphicsetId='13879';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FFFFFF';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Office',
				paletteFamily: 	'727D9C',
				keyvisualId: 	'11165',
				keyvisualName: 	'kv_11165.jpg',
				fontsetId: 		'32065',
				graphicsetId: 	'13879',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'false',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '31901',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '801',
internalId:  '',
customField: '20091128-114222'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '852',
internalId:  '',
customField: '20091128-120453'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '873',
internalId:  '',
customField: '20090621-003959'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '44201',
internalId:  '',
customField: '20090713-104010'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26301',
internalId:  '',
customField: '20090628-221256'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26322',
internalId:  '',
customField: '20090708-000548'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '42901',
internalId:  '',
customField: '20091128-113042'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '41401',
internalId:  '',
customField: '20090706-225353'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '41101',
internalId:  '',
customField: '20090628-221449'
};
webappMappings['8002']=webappMappings['8002-search']={
webappId:    '8002',
documentId:  '29669',
internalId:  'search',
customField: 'language:en;country:US;'
};
webappMappings['1501']=webappMappings['1501-20312243']={
webappId:    '1501',
documentId:  '31901',
internalId:  '20312243',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29543',
internalId:  '',
customField: '20090621-025623'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29585',
internalId:  '',
customField: '20090620-222913'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29522',
internalId:  '',
customField: '20090621-025525'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29564',
internalId:  '',
customField: '20090621-000258'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '41422',
internalId:  '',
customField: '20090825-221824'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '41443',
internalId:  '',
customField: '20091019-104852'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34601',
internalId:  '',
customField: '20090719-145629'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29669',
internalId:  '',
customField: '20090617-124855'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31901',
internalId:  '',
customField: '20091019-104527'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29711',
internalId:  '',
customField: '20090825-130619'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33101',
internalId:  '',
customField: '20090621-051934'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33301',
internalId:  '',
customField: '20090621-002740'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '45101',
internalId:  '',
customField: '20091128-120934'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '48201',
internalId:  '',
customField: '20090719-152359'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '48601',
internalId:  '',
customField: '20090719-153325'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '49122',
internalId:  '',
customField: '20090720-134620'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '49101',
internalId:  '',
customField: '20090809-013349'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '50801',
internalId:  '',
customField: '20090809-011627'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '51101',
internalId:  '',
customField: '20090808-192002'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '51122',
internalId:  '',
customField: '20090808-192002'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '51143',
internalId:  '',
customField: '20090808-192002'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '54901',
internalId:  '',
customField: '20100209-222555'
};
var canonHostname = 'wscwrk02.ehost-services.com';
var accountId     = 'AEN010INVKS9';
var companyName   = 'exceedfitness';
var htmlTitle	  = 'excedfitness+-+triathlon%2Crunning%2Cswimming%2Cpersonal+training%2Clearn+to+swim%2C+swim+coaching%2C';
var metaKeywords  = 'TRIATHLON+COACHING++TRIATHLON+TRAINING+PROGRAMS++SWIM+COACHING++SWIM+TRAINING+PROGRAMS++PERSONAL+TRAINING++BOOT+CAMPS++ADVENTURE+CHALLENGES++CANBERRA++JERRABOMBERRA++CHOLESTEROL++GLUCOSE++GROUP+TRAINING+++EXCEED++EXCEEDFITNESS++FITNESS++EXCEED+FITNESS+LACTATE+TESTING+ALTITUDE+TRAINING++++++';
var metaContents  = '';
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();
};
