/* [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','10',jdecode('Home'),jdecode(''),'/10.html','true',[],''],
	['PAGE','11',jdecode('Contact Us'),jdecode(''),'/11.html','true',[],''],
	['PAGE','13',jdecode('Anchors'),jdecode(''),'/13.html','true',[],''],
	['PAGE','14',jdecode('Bimini & Deck'),jdecode(''),'/14.html','true',[],''],
	['PAGE','15',jdecode('Blocks & Sheaves'),jdecode(''),'/15.html','true',[],''],
	
	['PAGE','16',jdecode('Chains'),jdecode(''),'/16.html','true',[],''],
	['PAGE','17',jdecode('Deck Hardware'),jdecode(''),'/17.html','true',[],''],	
	['PAGE','18',jdecode('Eye & U Bolts'),jdecode(''),'/18.html','true',[],''],

	['PAGE','19',jdecode('Hinges + Hasps'),jdecode(''),'/19.html','true',[],''],
	['PAGE','20',jdecode('Hocks + Clips'),jdecode(''),'/20.html','true',[],''],
	
	
	
	['PAGE','21',jdecode('LED Microstar & Electrical'),jdecode(''),'/21.html','true',[],''],
	['PAGE','22',jdecode('Life Line'),jdecode(''),'/22.html','true',[],''],
	['PAGE','23',jdecode('Nitronic 50'),jdecode(''),'/23.html','true',[],''],
	['PAGE','24',jdecode('Other'),jdecode(''),'/24.html','true',[],''],
	['PAGE','25',jdecode('Pad Eyes'),jdecode(''),'/25.html','true',[],''],
	['PAGE','26',jdecode('Railing Systems'),jdecode(''),'/26.html','true',[],''],
	
	['PAGE','27',jdecode('Rigging'),jdecode(''),'/27.html','true',[],''],
	['PAGE','28',jdecode('Shackles'),jdecode(''),'/28.html','true',[],''],
	['PAGE','29',jdecode('Swage Terminals'),jdecode(''),'/29.html','true',[],''],
	['PAGE','30',jdecode('Swagless / Quick Attach'),jdecode(''),'/30.html','true',[],''],
	['PAGE','31',jdecode('Tie Downs & Webbing'),jdecode(''),'/31.html','true',[],''],

	['PAGE','32',jdecode('Titanium'),jdecode(''),'/32.html','true',[],''],
	['PAGE','33',jdecode('Tools'),jdecode(''),'/33.html','true',[],''],
	['PAGE','34',jdecode('Trailer'),jdecode(''),'/34.html','true',[],''],
	['PAGE','35',jdecode('Turnbuckle'),jdecode(''),'/35.html','true',[],''],
	
	['PAGE','36',jdecode('Wire+Rope'),jdecode(''),'/36.html','true',[],''],
	
	
	
	
	['PAGE','38',jdecode('Services'),jdecode(''),'/38.html','true',[],''],
	
	['PAGE','539',jdecode('Directions'),jdecode(''),'/539.html','true',[],''],
	['PAGE','564',jdecode('data'),jdecode(''),'/564.html','true',[],''],
	['PAGE','576',jdecode('Parts'),jdecode(''),'/576.html','true',[],'']];
var siteelementCount=5;
theSitetree.topTemplateName='Angkor';
theSitetree.paletteFamily='879ED6';
theSitetree.keyvisualId='6854';
theSitetree.keyvisualName='kv_6854.jpg';
theSitetree.fontsetId='11212';
theSitetree.graphicsetId='12030';
theSitetree.contentColor='354B86';
theSitetree.contentBGColor='94AAE1';
var theTemplate={
				name: 			'Angkor'
,				paletteFamily: 	'879ED6'
,				keyvisualId: 	'6854'
,				keyvisualName: 	'kv_6854.jpg'
,				fontsetId: 		'11212'
,				graphicsetId: 	'12030'
,				contentColor: 	'354B86'
,				contentBGColor: '94AAE1'
,				a_color: 		'94AAE1'
,				b_color: 		'000000'
,				c_color: 		'000000'
,				d_color: 		'000000'
,				e_color: 		'000000'
,				f_color: 		'000000'
 			  };					                                                                    
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 */					                                                            

