/* [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','5201',jdecode('Home'),jdecode(''),'/5201.html','true',[],'',''],
	['PAGE','6901',jdecode('Current+Projects'),jdecode(''),'/6901.html','true',[],'',''],
	['PAGE','5252',jdecode('Merchandise%2FFundraising'),jdecode(''),'/5252.html','true',[],'',''],
	['PAGE','5273',jdecode('Make+a+Difference%21'),jdecode(''),'/5273.html','true',[],'',''],
	['PAGE','5294',jdecode('Racing+for+the+Cure%21'),jdecode(''),'/5294/index.html','true',[ 
		['PAGE','9801',jdecode('Race+Remembrances'),jdecode(''),'/5294/9801.html','true',[],'',''],
		['PAGE','14801',jdecode('COS+Stuff...'),jdecode(''),'/5294/14801.html','true',[],'','']
	],'',''],
	['PAGE','5315',jdecode('Promoting+Others%21'),jdecode(''),'/5315/index.html','true',[ 
		['PAGE','5399',jdecode('Colorado+Rockies'),jdecode(''),'/5315/5399.html','true',[],'',''],
		['PAGE','5420',jdecode('Teller+County+4H+%26+Fair%21'),jdecode(''),'/5315/5420.html','true',[],'',''],
		['PAGE','5357',jdecode('4H+Marrow+Drive'),jdecode(''),'/5315/5357.html','true',[],'',''],
		['PAGE','5378',jdecode('Quilting%2C+Photography+%2B'),jdecode(''),'/5315/5378.html','true',[],'',''],
		['PAGE','14601',jdecode('DFW+Home+Guide'),jdecode(''),'/5315/14601.html','true',[],'',''],
		['PAGE','5336',jdecode('Rockin%26%23x27%3B+for+the+PINK%21'),jdecode(''),'/5315/5336.html','true',[],'','']
	],'',''],
	['PAGE','5441',jdecode('Bio'),jdecode(''),'/5441.html','true',[],'',''],
	['PAGE','5462',jdecode('Contact'),jdecode(''),'/5462.html','true',[],'',''],
	['PAGE','12901',jdecode('Fun+Stuff%2Flinks....'),jdecode(''),'/12901.html','true',[],'',''],
	['PAGE','5483',jdecode('Sign+My+Guestbook%21'),jdecode(''),'/5483.html','true',[],'','']];
var siteelementCount=18;
theSitetree.topTemplateName='Kreis';
theSitetree.paletteFamily='D24C59';
theSitetree.keyvisualId='606';
theSitetree.keyvisualName='federn.jpg';
theSitetree.fontsetId='127';
theSitetree.graphicsetId='143';
theSitetree.contentColor='F877A1';
theSitetree.contentBGColor='000000';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Kreis',
				paletteFamily: 	'D24C59',
				keyvisualId: 	'606',
				keyvisualName: 	'federn.jpg',
				fontsetId: 		'127',
				graphicsetId: 	'143',
				contentColor: 	'F877A1',
				contentBGColor: '000000',
				a_color: 		'D24C59',
				b_color: 		'F877A1',
				c_color: 		'000000',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'false',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['7008']=webappMappings['7008-2940']={
webappId:    '7008',
documentId:  '5462',
internalId:  '2940',
customField: 'language:en;country:US;'
};
webappMappings['1002']=webappMappings['1002-5483ahw050inldsh']={
webappId:    '1002',
documentId:  '5483',
internalId:  '5483ahw050inldsh',
customField: 'icq=false'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5201',
internalId:  '',
customField: '20110708-073905'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '5201',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6901',
internalId:  '',
customField: '20110708-072736'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5252',
internalId:  '',
customField: '20090418-140419'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5273',
internalId:  '',
customField: '20090418-141225'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5294',
internalId:  '',
customField: '20090418-141450'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9801',
internalId:  '',
customField: '20090418-180024'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5441',
internalId:  '',
customField: '20090419-094426'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5420',
internalId:  '',
customField: '20100630-080218'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5399',
internalId:  '',
customField: '20090420-111721'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5357',
internalId:  '',
customField: '20090418-210547'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5315',
internalId:  '',
customField: '20090701-100106'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5378',
internalId:  '',
customField: '20090418-211419'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5336',
internalId:  '',
customField: '20090418-210902'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14601',
internalId:  '',
customField: '20090418-211223'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14801',
internalId:  '',
customField: '20090418-211805'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5483',
internalId:  '',
customField: '20090418-113153'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5462',
internalId:  '',
customField: '20110708-074037'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '12901',
internalId:  '',
customField: '20090504-081250'
};
var canonHostname = 'wsc-worker01.chi.us.siteprotect.com';
var accountId     = 'AHW050INLDSH';
var companyName   = 'Run2Infinity+...+and+beyond%21';
var htmlTitle	  = 'Running+for+HOPE+...+and+to+infiinity%21';
var metaKeywords  = 'running+survivor+breast+cancer+hope+pink+buzz+lightyear';
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();
};

