/* [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','1115',jdecode('Home'),jdecode(''),'/1115.html','true',[],''],
	['PAGE','9989',jdecode('Die+Lautsprecher...'),jdecode(''),'/9989/index.html','true',[ 
		['PAGE','26259',jdecode('Testberichte'),jdecode(''),'/9989/26259.html','true',[],'']
	],''],
	['PAGE','19221',jdecode('Der+Verst%E4rker...'),jdecode(''),'/19221.html','true',[],''],
	['PAGE','19248',jdecode('Die+Frequenzweiche...'),jdecode(''),'/19248.html','true',[],''],
	['PAGE','35932',jdecode('Christians+System'),jdecode(''),'/35932.html','true',[],''],
	['PAGE','22723',jdecode('Projekte'),jdecode(''),'/22723/index.html','true',[ 
		['PAGE','27006',jdecode('Links'),jdecode(''),'/22723/27006.html','true',[],'']
	],''],
	['PAGE','19275',jdecode('Musiktipps'),jdecode(''),'/19275.html','true',[],''],
	['PAGE','28532',jdecode('Downloads+%2F+Baupl%E4ne'),jdecode(''),'/28532/index.html','true',[ 
		['PAGE','42445',jdecode('ACR+%2F+Fostex+%2F+Lowther'),jdecode(''),'/28532/42445.html','true',[],''],
		['PAGE','42472',jdecode('andere'),jdecode(''),'/28532/42472.html','true',[],''],
		['PAGE','42499',jdecode('Frequenzweichen'),jdecode(''),'/28532/42499.html','true',[],''],
		['PAGE','42526',jdecode('Grundlagen+%2F+Datenbl%E4tter'),jdecode(''),'/28532/42526.html','true',[],''],
		['PAGE','42553',jdecode('JBL+Paragon'),jdecode(''),'/28532/42553.html','true',[],'']
	],''],
	['PAGE','19302',jdecode('Kontakt'),jdecode(''),'/19302/index.html','true',[ 
		['PAGE','56722',jdecode('Kontakt+%28Folgeseite%29'),jdecode(''),'/19302/56722.html','false',[],'']
	],''],
	['PAGE','19829',jdecode('G%E4stebuch'),jdecode(''),'/19829/index.html','true',[ 
		['PAGE','19830',jdecode('Eintr%E4ge'),jdecode(''),'/19829/19830.html','true',[],'']
	],'']];
var siteelementCount=19;
theSitetree.topTemplateName='Inspiration';
					                                                                    
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 */					                                                            
