/* [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','4466',jdecode('Home'),jdecode(''),'/4466.html','true',[],''],
	['PAGE','378235',jdecode('NEWS+ab+01.01.2011'),jdecode(''),'/378235.html','true',[],''],
	['PAGE','318519',jdecode('NEWS+ab+06.01.2010'),jdecode(''),'/318519/index.html','true',[ 
		['PAGE','288431',jdecode('NEWS+ab+01.01.2009'),jdecode(''),'/318519/288431.html','true',[],'']
	],''],
	['PAGE','316315',jdecode('DVM+2010'),jdecode(''),'/316315.html','true',[],''],
	['PAGE','306338',jdecode('Termine+2009%2F10'),jdecode(''),'/306338.html','true',[],''],
	['PAGE','69841',jdecode('Jugendreise+2011'),jdecode(''),'/69841.html','true',[],''],
	['PAGE','252427',jdecode('TuRa+Erwachsene'),jdecode(''),'/252427/index.html','true',[ 
		['PAGE','252476',jdecode('Das+sind+WIR+%28Folgeseite%29'),jdecode(''),'/252427/252476.html','false',[],'']
	],''],
	['PAGE','22173',jdecode('TuRa+J-I'),jdecode(''),'/22173.html','true',[],''],
	['PAGE','22732',jdecode('TuRa+J-II%2BIII'),jdecode(''),'/22732.html','true',[],''],
	['PAGE','22825',jdecode('TuRa+TRAINING'),jdecode(''),'/22825.html','true',[],''],
	['PAGE','22497',jdecode('Bilanz+seit+1996'),jdecode(''),'/22497/index.html','true',[ 
		['PAGE','204427',jdecode('TuRa+NEWS+ab+2008'),jdecode(''),'/22497/204427.html','true',[],''],
		['PAGE','318748',jdecode('Berichte+DVM'),jdecode(''),'/22497/318748.html','true',[],'']
	],'']];
var siteelementCount=15;
theSitetree.topTemplateName='Profile';
					                                                                    
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 */					                                                            

