/* [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 theSitetree=[ 
	['PAGE','4201',jdecode('Welcome+to+NKFC%21'),jdecode(''),'/4201/index.html','true',[ 
		['PAGE','27001',jdecode('Who+Are+We%3F'),jdecode(''),'/4201/27001.html','true',[],''],
		['PAGE','51701',jdecode('NKFC+Mission'),jdecode(''),'/4201/51701.html','true',[],'']
	],''],
	['PAGE','63701',jdecode('Press+Room'),jdecode(''),'/63701/index.html','true',[ 
		['PAGE','84312',jdecode('NKFC-CM7+PR'),jdecode(''),'/63701/84312.html','true',[],''],
		['PAGE','80212',jdecode('Conference+Rescheduled'),jdecode(''),'/63701/80212.html','false',[],'']
	],''],
	['PAGE','4252',jdecode('Registration'),jdecode(''),'/4252.html','true',[],''],
	['PAGE','31801',jdecode('Workshops'),jdecode(''),'/31801.html','true',[],''],
	['PAGE','4336',jdecode('Lodging'),jdecode(''),'/4336.html','true',[],''],
	['PAGE','4294',jdecode('Program'),jdecode(''),'/4294.html','false',[],''],
	['PAGE','65901',jdecode('Giving+to+NKFC'),jdecode(''),'/65901.html','true',[],''],
	['PAGE','69112',jdecode('Fundraising+Events'),jdecode(''),'/69112.html','true',[],''],
	['PAGE','37601',jdecode('Sponsors'),jdecode(''),'/37601.html','true',[],''],
	['PAGE','75912',jdecode('FAQs'),jdecode(''),'/75912.html','true',[],''],
	['PAGE','4315',jdecode('Exhibits'),jdecode(''),'/4315.html','false',[],''],
	['PAGE','31822',jdecode('Entertainment'),jdecode(''),'/31822.html','false',[],''],
	['PAGE','31843',jdecode('Interpreting+Services'),jdecode(''),'/31843.html','false',[],''],
	['PAGE','4357',jdecode('Volunteers'),jdecode(''),'/4357.html','false',[],''],
	['PAGE','4378',jdecode('NKFC+Blog'),jdecode(''),'/4378.html','false',[],''],
	['PAGE','51901',jdecode('Site+Map'),jdecode(''),'/51901.html','false',[],'']];
var siteelementCount=20;
theSitetree.topTemplateName='Plainly';
theSitetree.paletteFamily='F38847';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='32125';
theSitetree.graphicsetId='13928';
theSitetree.contentColor='6e6e6d';
theSitetree.contentBGColor='fcf5f9';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				name: 			'Plainly',
				paletteFamily: 	'F38847',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'32125',
				graphicsetId: 	'13928',
				contentColor: 	'6e6e6d',
				contentBGColor: 'fcf5f9',
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['7050']=webappMappings['7050-3928']={
webappId:    '7050',
documentId:  '4378',
internalId:  '3928',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4201',
internalId:  '',
customField: '20100202-132835'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4252',
internalId:  '',
customField: '20100401-102358'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '37601',
internalId:  '',
customField: '20091211-131816'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4294',
internalId:  '',
customField: '20081231-163302'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4315',
internalId:  '',
customField: '20080721-095559'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4336',
internalId:  '',
customField: '20100202-130631'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4357',
internalId:  '',
customField: '20080801-103549'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4378',
internalId:  '',
customField: '20080801-103601'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31801',
internalId:  '',
customField: '20100520-122716'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31822',
internalId:  '',
customField: '20080801-094158'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31843',
internalId:  '',
customField: '20080804-212725'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27001',
internalId:  '',
customField: '20090826-110807'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '51701',
internalId:  '',
customField: '20090826-110846'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '51901',
internalId:  '',
customField: '20080812-182551'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '63701',
internalId:  '',
customField: '20090925-074532'
};
webappMappings['1501']=webappMappings['1501-11399525']={
webappId:    '1501',
documentId:  '4201',
internalId:  '11399525',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '65901',
internalId:  '',
customField: '20081231-163736'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '69112',
internalId:  '',
customField: '20100202-134251'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '75912',
internalId:  '',
customField: '20090430-083936'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '80212',
internalId:  '',
customField: '20090826-110947'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '84312',
internalId:  '',
customField: '20090925-084317'
};
var canonHostname = 'cmworker01.yourhostingaccount.com';
var accountId     = 'AENDU0IN2FEG';
var companyName   = 'The+National+Kids+of+Deaf+Adults+Family+Conference';
var htmlTitle	  = 'The+National+Kids+of+Deaf+Adults+Family+Conference';
var metaKeywords  = '';
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();
};
