/* [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','2201',jdecode('Home'),jdecode(''), jdecode('%2F2201.html'), 'true',[],'',''],
	['PAGE','29639',jdecode('News+%26+FYI'),jdecode(''), jdecode('%2F29639%2Findex.html'), 'true',[ 
		['PAGE','29660',jdecode('Guestbook'),jdecode(''), jdecode('%2F29639%2F29660.html'), 'true',[],'',''],
		['PAGE','29681',jdecode('%22School+Scoop%22'),jdecode(''), jdecode('%2F29639%2F29681.html'), 'true',[],'',''],
		['PAGE','43950',jdecode('Scrapbook'),jdecode(''), jdecode('%2F29639%2F43950.html'), 'true',[],'',''],
		['PAGE','53050',jdecode('Applause'),jdecode(''), jdecode('%2F29639%2F53050.html'), 'true',[],'','']
	],'',''],
	['PAGE','2357',jdecode('About+Us'),jdecode(''), jdecode('%2F2357%2Findex.html'), 'true',[ 
		['PAGE','13139',jdecode('Mission+%26+Philosophy'),jdecode(''), jdecode('%2F2357%2F13139.html'), 'true',[],'',''],
		['PAGE','4739',jdecode('Why+Our+School%3F'),jdecode(''), jdecode('%2F2357%2F4739.html'), 'true',[],'',''],
		['PAGE','32639',jdecode('School+Board'),jdecode(''), jdecode('%2F2357%2F32639.html'), 'true',[],'',''],
		['PAGE','18539',jdecode('Faculty+and+Staff'),jdecode(''), jdecode('%2F2357%2F18539.html'), 'true',[],'',''],
		['PAGE','19039',jdecode('Contact+Us'),jdecode(''), jdecode('%2F2357%2F19039.html'), 'true',[],'',''],
		['PAGE','22139',jdecode('Map+%26+Directions'),jdecode(''), jdecode('%2F2357%2F22139.html'), 'true',[],'','']
	],'',''],
	['PAGE','28539',jdecode('Admissions'),jdecode(''), jdecode('%2F28539%2Findex.html'), 'true',[ 
		['PAGE','2273',jdecode('Registration+Info'),jdecode(''), jdecode('%2F28539%2F2273.html'), 'true',[],'',''],
		['PAGE','29139',jdecode('Tuition'),jdecode(''), jdecode('%2F28539%2F29139.html'), 'true',[],'',''],
		['PAGE','28639',jdecode('Uniform+Information'),jdecode(''), jdecode('%2F28539%2F28639.html'), 'true',[],'','']
	],'',''],
	['PAGE','27339',jdecode('Parent+Corner'),jdecode(''), jdecode('%2F27339%2Findex.html'), 'true',[ 
		['PAGE','2294',jdecode('Student+Handbook'),jdecode(''), jdecode('%2F27339%2F2294.html'), 'true',[],'',''],
		['PAGE','12139',jdecode('Official+Calendar'),jdecode(''), jdecode('%2F27339%2F12139.html'), 'true',[],'',''],
		['PAGE','57250',jdecode('Lunch'),jdecode(''), jdecode('%2F27339%2F57250.html'), 'true',[],'',''],
		['PAGE','27539',jdecode('Virtus+Info'),jdecode(''), jdecode('%2F27339%2F27539.html'), 'true',[],'',''],
		['PAGE','32139',jdecode('Service+Hours'),jdecode(''), jdecode('%2F27339%2F32139.html'), 'true',[],'',''],
		['PAGE','27560',jdecode('Forms'),jdecode(''), jdecode('%2F27339%2F27560.html'), 'true',[],'',''],
		['PAGE','27581',jdecode('Home+%26+School+'),jdecode(''), jdecode('%2F27339%2F27581.html'), 'true',[],'','']
	],'',''],
	['PAGE','32660',jdecode('Support'),jdecode(''), jdecode('%2F32660.html'), 'true',[],'',''],
	['PAGE','2315',jdecode('Alumni'),jdecode(''), jdecode('%2F2315%2Findex.html'), 'true',[ 
		['PAGE','35050',jdecode('%222008+Party%22'),jdecode(''), jdecode('%2F2315%2F35050.html'), 'true',[],'','']
	],'',''],
	['ITEM','38050',jdecode('OLOL+Church'),jdecode(''), jdecode('http%3A%2F%2Fololchurch.org%2F'), 'true',[],'','_blank']];
var siteelementCount=29;
theSitetree.topTemplateName='Aroundtheworld';
theSitetree.paletteFamily='7FACDC';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10790';
theSitetree.graphicsetId='11215';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='7FACDC';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'endurance',
  product: 'WSCSYSSSSLY0XRN4'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Aroundtheworld',
				paletteFamily: 	'7FACDC',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10790',
				graphicsetId: 	'11215',
				contentColor: 	'000000',
				contentBGColor: '7FACDC',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'true',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'true'
			  };
var webappMappings = {};
webappMappings['1002']=webappMappings['1002-2336aendu0in2bm2']={
webappId:    '1002',
documentId:  '2336',
internalId:  '2336aendu0in2bm2',
customField: 'icq=false'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2201',
internalId:  '',
customField: '20111024-111025'
};
webappMappings['1002']=webappMappings['1002-29660aendu0in2bm2']={
webappId:    '1002',
documentId:  '29660',
internalId:  '29660aendu0in2bm2',
customField: 'icq=false'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2273',
internalId:  '',
customField: '20110815-144631'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2294',
internalId:  '',
customField: '20110817-150728'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2315',
internalId:  '',
customField: '20110322-115323'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2336',
internalId:  '',
customField: '20090209-230436'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2357',
internalId:  '',
customField: '20111024-111046'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4760',
internalId:  '',
customField: '20090720-220004'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4739',
internalId:  '',
customField: '20100908-112425'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '2201',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '12139',
internalId:  '',
customField: '20110815-150428'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13139',
internalId:  '',
customField: '20100214-235521'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '18539',
internalId:  '',
customField: '20111201-143211'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19039',
internalId:  '',
customField: '20100907-134050'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22139',
internalId:  '',
customField: '20100907-134110'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27339',
internalId:  '',
customField: '20110322-134236'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27539',
internalId:  '',
customField: '20100908-144032'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27560',
internalId:  '',
customField: '20100908-093237'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28539',
internalId:  '',
customField: '20110630-091321'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29139',
internalId:  '',
customField: '20110322-134100'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29639',
internalId:  '',
customField: '20120126-110641'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29681',
internalId:  '',
customField: '20100907-180436'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28639',
internalId:  '',
customField: '20110630-091510'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27581',
internalId:  '',
customField: '20111003-092636'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '32139',
internalId:  '',
customField: '20110712-093110'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '32639',
internalId:  '',
customField: '20110322-113418'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '32660',
internalId:  '',
customField: '20110914-122533'
};
webappMappings['7008']=webappMappings['7008-31096']={
webappId:    '7008',
documentId:  '2315',
internalId:  '31096',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29660',
internalId:  '',
customField: '20100908-141200'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '35050',
internalId:  '',
customField: '20100921-103453'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43950',
internalId:  '',
customField: '20110902-093509'
};
webappMappings['1501']=webappMappings['1501-38514877']={
webappId:    '1501',
documentId:  '2201',
internalId:  '38514877',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '53050',
internalId:  '',
customField: '20120118-140424'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '57250',
internalId:  '',
customField: '20110819-101829'
};
var webAppHostname = 'cgiwsc.enhancedsitebuilder.com:80';
var canonHostname = 'cmworker02.yourhostingaccount.com';
var accountId     = 'AENDU0IN2BM2';
var companyName   = 'Our+Lady+of+Lourdes+Catholic+School+-+Hitchock%2C+TX';
var htmlTitle	  = 'Our+Lady+of+Lourdes+Catholic+School';
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();
};

