/* [nodename, id, name, navigationtext, href, isnavigation, childs[], templatename] */

function jdecode(s) {
    s = s.replace(/\+/g, "%20")
    return unescape(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','401',jdecode('Welcome'),jdecode(''),'/401.html','true',[],''],
	['PAGE','81401',jdecode('Summer+Splurge+2011'),jdecode(''),'/81401.html','true',[],''],
	['PAGE','82501',jdecode('Summer+Activites+2011'),jdecode(''),'/82501.html','true',[],''],
	['PAGE','58301',jdecode('New+Events'),jdecode(''),'/58301.html','true',[],''],
	['PAGE','61001',jdecode('Community+Cleanup'),jdecode(''),'/61001.html','true',[],''],
	['PAGE','60101',jdecode('Holiday+Club+2011'),jdecode(''),'/60101.html','true',[],''],
	['PAGE','79201',jdecode('Bishop+visits+Project'),jdecode(''),'/79201.html','true',[],''],
	['PAGE','69701',jdecode('Youth+Activities'),jdecode(''),'/69701.html','true',[],''],
	['PAGE','57601',jdecode('Information+Day'),jdecode(''),'/57601.html','true',[],''],
	['PAGE','78301',jdecode('Recycling'),jdecode(''),'/78301.html','true',[],''],
	['PAGE','7601',jdecode('Where+to+find+us'),jdecode(''),'/7601.html','true',[],''],
	['PAGE','473',jdecode('Afterschool+Club'),jdecode(''),'/473.html','true',[],''],
	['PAGE','22101',jdecode('Holiday+Playscheme'),jdecode(''),'/22101.html','true',[],''],
	['PAGE','515',jdecode('All+Saints+UK+Online'),jdecode(''),'/515.html','true',[],''],
	['PAGE','9201',jdecode('Training'),jdecode(''),'/9201/index.html','true',[ 
		['PAGE','42301',jdecode('Saturday+Computers'),jdecode(''),'/9201/42301.html','true',[],'']
	],''],
	['PAGE','50501',jdecode('Exercise+Class'),jdecode(''),'/50501.html','true',[],''],
	['PAGE','599',jdecode('Lunch+Club'),jdecode(''),'/599.html','true',[],''],
	['PAGE','620',jdecode('Pram+Club'),jdecode(''),'/620.html','true',[],''],
	['PAGE','662',jdecode('Have+A+Go+Sessions'),jdecode(''),'/662/index.html','true',[ 
		['PAGE','13401',jdecode('Timetable'),jdecode(''),'/662/13401.html','true',[],'']
	],''],
	['PAGE','536',jdecode('Walking+Group'),jdecode(''),'/536/index.html','true',[ 
		['PAGE','16122',jdecode('Walking+Group+Info'),jdecode(''),'/536/16122.html','true',[],''],
		['PAGE','28001',jdecode('Walk+Photos'),jdecode(''),'/536/28001.html','true',[],'']
	],''],
	['PAGE','17501',jdecode('Other+Groups+in+Area'),jdecode(''),'/17501/index.html','true',[ 
		['PAGE','76301',jdecode('Board+Room+Cafe'),jdecode(''),'/17501/76301.html','true',[],''],
		['PAGE','20922',jdecode('Faith+in+the+Gateway'),jdecode(''),'/17501/20922.html','true',[],''],
		['PAGE','83401',jdecode('Football+Yr+2+%26+3'),jdecode(''),'/17501/83401.html','true',[],''],
		['PAGE','86801',jdecode('Medway+Foodbank'),jdecode(''),'/17501/86801.html','true',[],''],
		['PAGE','61022',jdecode('Medway+Renaissance'),jdecode(''),'/17501/61022.html','true',[],''],
		['PAGE','20901',jdecode('NKFC'),jdecode(''),'/17501/20901.html','true',[],''],
		['PAGE','17522',jdecode('SureStart'),jdecode(''),'/17501/17522.html','true',[],''],
		['PAGE','24201',jdecode('SureStart+Walking+Group'),jdecode(''),'/17501/24201.html','true',[],'']
	],''],
	['PAGE','51601',jdecode('Residents+Association'),jdecode(''),'/51601/index.html','true',[ 
		['PAGE','65301',jdecode('Police+Team+Surgeries'),jdecode(''),'/51601/65301.html','true',[],''],
		['PAGE','68801',jdecode('Community+Champions'),jdecode(''),'/51601/68801.html','true',[],'']
	],''],
	['PAGE','52901',jdecode('Faiths+in+Action'),jdecode(''),'/52901.html','true',[],'']];
var siteelementCount=37;
theSitetree.topTemplateName='Surround';
theSitetree.paletteFamily='5944D9';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10514';
theSitetree.graphicsetId='11135';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='5764B2';
var theTemplate={
				name: 			'Surround',
				paletteFamily: 	'5944D9',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10514',
				graphicsetId: 	'11135',
				contentColor: 	'FFFFFF',
				contentBGColor: '5764B2',
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'8386EC',
				e_color: 		'8386EC',
				f_color: 		'8386EC',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12'
			  };
var webappMappings = {};
webappMappings['5000']={
webappId:    '5000',
documentId:  '401',
internalId:  '',
customField: '20111030-214719'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '9201',
internalId:  '',
customField: '20110908-000016'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '473',
internalId:  '',
customField: '20110405-122824'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '79201',
internalId:  '',
customField: '20110516-104239'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '515',
internalId:  '',
customField: '20110503-231656'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '536',
internalId:  '',
customField: '20110223-134952'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '61001',
internalId:  '',
customField: '20100805-004946'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '61022',
internalId:  '',
customField: '20100805-002851'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '599',
internalId:  '',
customField: '20090614-185344'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '620',
internalId:  '',
customField: '20090614-185515'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '69701',
internalId:  '',
customField: '20110703-205621'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '662',
internalId:  '',
customField: '20110407-144304'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '7601',
internalId:  '',
customField: '20071220-001020'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '81401',
internalId:  '',
customField: '20110817-233832'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '58301',
internalId:  '',
customField: '20110503-231615'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '60101',
internalId:  '',
customField: '20110518-114156'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '13401',
internalId:  '',
customField: '20110720-121825'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '24201',
internalId:  '',
customField: '20090327-133354'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '28001',
internalId:  '',
customField: '20090614-184225'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '16122',
internalId:  '',
customField: '20111130-115629'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '68801',
internalId:  '',
customField: '20110317-170444'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '57601',
internalId:  '',
customField: '20100522-194751'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '52901',
internalId:  '',
customField: '20100207-153216'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '17501',
internalId:  '',
customField: '20111123-104944'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '17522',
internalId:  '',
customField: '20090614-190337'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '65301',
internalId:  '',
customField: '20100921-235121'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '42301',
internalId:  '',
customField: '20110817-230834'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '20901',
internalId:  '',
customField: '20090614-190936'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '20922',
internalId:  '',
customField: '20090614-191036'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '22101',
internalId:  '',
customField: '20110516-103624'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '51601',
internalId:  '',
customField: '20110216-111624'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '50501',
internalId:  '',
customField: '20110817-223422'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '76301',
internalId:  '',
customField: '20110419-153940'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '78301',
internalId:  '',
customField: '20110516-103429'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '82501',
internalId:  '',
customField: '20110703-205949'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '83401',
internalId:  '',
customField: '20110720-120644'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '86801',
internalId:  '',
customField: '20111123-104633'
};
var canonHostname = 'creator.amenworld.com';
var accountId     = 'AAM010INLR36';
var companyName   = 'All+Saints+Community+Project';
var htmlTitle	  = 'All+Saints+Community+Project';
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;                                                                     
	};                                                                               
/* EOF */					                                                            

