/* [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','1901',jdecode('Home'),jdecode(''), jdecode('%2F1901.html'), 'true',[],'',''],
	['PAGE','124301',jdecode('Eagles+News+'),jdecode(''), jdecode('%2F124301.html'), 'true',[],'',''],
	['PAGE','244795',jdecode('2011+Schedule'),jdecode(''), jdecode('%2F244795.html'), 'true',[],'',''],
	['PAGE','245095',jdecode('2011+Scores'),jdecode(''), jdecode('%2F245095.html'), 'true',[],'',''],
	['PAGE','245695',jdecode('2011+Standings'),jdecode(''), jdecode('%2F245695.html'), 'true',[],'',''],
	['PAGE','252895',jdecode('2011+Playoffs'),jdecode(''), jdecode('%2F252895.html'), 'true',[],'',''],
	['PAGE','236195',jdecode('Fall+Divisions'),jdecode(''), jdecode('%2F236195.html'), 'true',[],'',''],
	['ITEM','228695',jdecode('Eagles+Facebook'),jdecode(''), jdecode('http%3A%2F%2Fwww.facebook.com%2Fsouthbay.eagles%2Fposts%2F158253454222443%3Fref%3Dnotif%26notif_t%3Dlike%23%21%2Fsouthbay.eagles'), 'true',[],'','_blank'],
	['PAGE','2036',jdecode('Board+of+Directors'),jdecode(''), jdecode('%2F2036%2Findex.html'), 'true',[ 
		['PAGE','106801',jdecode('Executive+Board'),jdecode(''), jdecode('%2F2036%2F106801.html'), 'true',[],'',''],
		['PAGE','106822',jdecode('General+Board'),jdecode(''), jdecode('%2F2036%2F106822.html'), 'true',[],'','']
	],'',''],
	['PAGE','90001',jdecode('+Teams+%26+Coaches'),jdecode(''), jdecode('%2F90001%2Findex.html'), 'true',[ 
		['PAGE','142013',jdecode('2010+Eagles'),jdecode(''), jdecode('%2F90001%2F142013.html'), 'true',[],'',''],
		['PAGE','226395',jdecode('2011+Eagles'),jdecode(''), jdecode('%2F90001%2F226395.html'), 'true',[],'',''],
		['PAGE','177195',jdecode('Cheer+%26+Mascot'),jdecode(''), jdecode('%2F90001%2F177195.html'), 'true',[],'',''],
		['PAGE','124001',jdecode('Flag'),jdecode(''), jdecode('%2F90001%2F124001.html'), 'true',[],'',''],
		['PAGE','90422',jdecode('Mitey+Mite'),jdecode(''), jdecode('%2F90001%2F90422.html'), 'true',[],'',''],
		['PAGE','90443',jdecode('Jr.+Pee+Wee'),jdecode(''), jdecode('%2F90001%2F90443.html'), 'true',[],'',''],
		['PAGE','90464',jdecode('Pee+Wee'),jdecode(''), jdecode('%2F90001%2F90464.html'), 'true',[],'',''],
		['PAGE','90506',jdecode('Midget'),jdecode(''), jdecode('%2F90001%2F90506.html'), 'true',[],'','']
	],'',''],
	['PAGE','182695',jdecode('Eagles+In+Action%21%21'),jdecode(''), jdecode('%2F182695.html'), 'true',[],'',''],
	['PAGE','90022',jdecode('Home+Field'),jdecode(''), jdecode('%2F90022.html'), 'true',[],'',''],
	['PAGE','90043',jdecode('Field+Directions'),jdecode(''), jdecode('%2F90043.html'), 'true',[],'',''],
	['PAGE','161753',jdecode('Events'),jdecode(''), jdecode('%2F161753.html'), 'true',[],'',''],
	['PAGE','17901',jdecode('Sponsorship+'),jdecode(''), jdecode('%2F17901.html'), 'true',[],'',''],
	['PAGE','116001',jdecode('Sponsors+'),jdecode(''), jdecode('%2F116001.html'), 'true',[],'',''],
	['PAGE','90222',jdecode('Guestbook'),jdecode(''), jdecode('%2F90222.html'), 'true',[],'',''],
	['PAGE','2099',jdecode('Contact+Us'),jdecode(''), jdecode('%2F2099.html'), 'true',[],'',''],
	['PAGE','234295',jdecode('Fall+Registrations+'),jdecode(''), jdecode('%2F234295.html'), 'true',[],'',''],
	['PAGE','113001',jdecode('Spring+8%26%23x27%3Bs'),jdecode(''), jdecode('%2F113001.html'), 'true',[],'',''],
	['PAGE','35201',jdecode('PayPal+Payment'),jdecode(''), jdecode('%2F35201.html'), 'true',[],'',''],
	['PAGE','2057',jdecode('Volunteer+'),jdecode(''), jdecode('%2F2057.html'), 'true',[],'',''],
	['PAGE','40401',jdecode('Forms+%26+Handouts'),jdecode(''), jdecode('%2F40401.html'), 'true',[],'',''],
	['PAGE','220695',jdecode('SDYFC+Assoc.'),jdecode(''), jdecode('%2F220695.html'), 'true',[],'',''],
	['PAGE','111401',jdecode('FAQ%26%23x27%3BS'),jdecode(''), jdecode('%2F111401.html'), 'true',[],'',''],
	['PAGE','114401',jdecode('Links'),jdecode(''), jdecode('%2F114401.html'), 'true',[],'','']];
var siteelementCount=36;
theSitetree.topTemplateName='Circulation';
theSitetree.paletteFamily='2FAF66';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10587';
theSitetree.graphicsetId='10565';
theSitetree.contentColor='DDDDDD';
theSitetree.contentBGColor='000000';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'endurance',
  product: 'WSCSYSSSSLY0XRNU'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Circulation',
				paletteFamily: 	'2FAF66',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10587',
				graphicsetId: 	'10565',
				contentColor: 	'DDDDDD',
				contentBGColor: '000000',
				a_color: 		'FFFFFF',
				b_color: 		'FFFFFF',
				c_color: 		'FFFFFF',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1901',
internalId:  '',
customField: '20110526-172941'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '35201',
internalId:  '',
customField: '20100123-122932'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '40401',
internalId:  '',
customField: '20110617-213442'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2036',
internalId:  '',
customField: '20110413-153300'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2057',
internalId:  '',
customField: '20110131-161328'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '17901',
internalId:  '',
customField: '20110419-163116'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2099',
internalId:  '',
customField: '20100216-235904'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '1901',
internalId:  '1006',
customField: '1006'
};
webappMappings['4001']=webappMappings['4001-16739441']={
webappId:    '4001',
documentId:  '35201',
internalId:  '16739441',
customField: 'language:en;country:US;'
};
webappMappings['2001']=webappMappings['2001-location']={
webappId:    '2001',
documentId:  '90022',
internalId:  'location',
customField: 'language:en;country:US;isIncluded:true;'
};
webappMappings['2002']=webappMappings['2002-routing']={
webappId:    '2002',
documentId:  '90043',
internalId:  'routing',
customField: 'en_US'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90001',
internalId:  '',
customField: '20110822-131807'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90022',
internalId:  '',
customField: '20090409-131214'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90043',
internalId:  '',
customField: '20090401-001925'
};
webappMappings['1002']=webappMappings['1002-90222aendu0in2st6']={
webappId:    '1002',
documentId:  '90222',
internalId:  '90222aendu0in2st6',
customField: 'icq=false'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90222',
internalId:  '',
customField: '20100319-060108'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '245695',
internalId:  '',
customField: '20111024-174849'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '252895',
internalId:  '',
customField: '20111024-174733'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90464',
internalId:  '',
customField: '20110912-140222'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '244795',
internalId:  '',
customField: '20111010-175718'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90506',
internalId:  '',
customField: '20110912-135544'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90422',
internalId:  '',
customField: '20110912-134543'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '90443',
internalId:  '',
customField: '20110912-134626'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '106801',
internalId:  '',
customField: '20110912-132633'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '106822',
internalId:  '',
customField: '20110912-132931'
};
webappMappings['7060']=webappMappings['7060-4d1be05da334068f2b9070c1048bfacb']={
webappId:    '7060',
documentId:  '182695',
internalId:  '4d1be05da334068f2b9070c1048bfacb',
customField: 'language:en;country:US;'
};
webappMappings['1501']=webappMappings['1501-11591131']={
webappId:    '1501',
documentId:  '1901',
internalId:  '11591131',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '111401',
internalId:  '',
customField: '20100123-123706'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '113001',
internalId:  '',
customField: '20110325-140934'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '114401',
internalId:  '',
customField: '20110125-140332'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '116001',
internalId:  '',
customField: '20110617-215006'
};
webappMappings['7008']=webappMappings['7008-18223']={
webappId:    '7008',
documentId:  '2099',
internalId:  '18223',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '124301',
internalId:  '',
customField: '20110822-131448'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '124001',
internalId:  '',
customField: '20110912-134458'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '182695',
internalId:  '',
customField: '20101220-175932'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '236195',
internalId:  '',
customField: '20110329-185153'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '220695',
internalId:  '',
customField: '20101124-164045'
};
webappMappings['7060']=webappMappings['7060-887bbba99c4baa387f33d2ffbf8ce843']={
webappId:    '7060',
documentId:  '142013',
internalId:  '887bbba99c4baa387f33d2ffbf8ce843',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '177195',
internalId:  '',
customField: '20110912-134317'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '142013',
internalId:  '',
customField: '20101124-170946'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '226395',
internalId:  '',
customField: '20101220-174925'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '161753',
internalId:  '',
customField: '20110608-174736'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '234295',
internalId:  '',
customField: '20110726-164200'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '245095',
internalId:  '',
customField: '20111024-173735'
};
var webAppHostname = 'cgiwsc.enhancedsitebuilder.com:80';
var canonHostname = 'cmworker03.yourhostingaccount.com';
var accountId     = 'AENDU0IN2ST6';
var companyName   = 'Welcome+To+The+Eagles+Nest';
var htmlTitle	  = 'South+Bay+Youth+Football+%26+Cheer+Association';
var metaKeywords  = 'South+Bay+Eagles+Youth+Football+San+Diego+Youth+Football+South+Bay+El+Toyon+Park+National+City+Eagles+Cheer+Youth+Football';
var metaContents  = 'South+Bay+Eagles+Youth+Football+San+Diego+Youth+Football+South+Bay+El+Toyon+Park+National+City+Eagles+Cheer+Youth+Football';
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();
};

