/* [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','1001',jdecode('ESCUELA+TECSUB'),jdecode(''),'/1001.html','true',[],''],
	['PAGE','1094',jdecode('OPEN+WATER+DIVER'),jdecode(''),'/1094.html','true',[],''],
	['PAGE','1115',jdecode('ADVANCED'),jdecode(''),'/1115.html','true',[],''],
	['PAGE','1136',jdecode('EFR-RESCUE'),jdecode(''),'/1136.html','true',[],''],
	['PAGE','1157',jdecode('DIVEMASTER'),jdecode(''),'/1157.html','true',[],''],
	['PAGE','1073',jdecode('OFER.+SEGUROS+%2F%2F+MATERIAL'),jdecode(''),'/1073.html','true',[],''],
	['PAGE','1199',jdecode('VIAJES'),jdecode(''),'/1199.html','true',[],''],
	['PAGE','20512',jdecode('FOTOS+'),jdecode(''),'/20512.html','true',[],''],
	['PAGE','10201',jdecode('CONTACTO+%2F%2F+LINKS'),jdecode(''),'/10201/index.html','true',[ 
		['PAGE','11401',jdecode('CONTACTO+%28follow+up+page%29'),jdecode(''),'/10201/11401.html','false',[],'']
	],'']];
var siteelementCount=10;
theSitetree.topTemplateName='Moonflight';
theSitetree.paletteFamily='5B7A93';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='446';
theSitetree.graphicsetId='499';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FFFFFF';
var theTemplate={
				name: 			'Moonflight',
				paletteFamily: 	'5B7A93',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'446',
				graphicsetId: 	'499',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				a_color: 		'2C5574',
				b_color: 		'FFFFFF',
				c_color: 		'FFFFFF',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'false',
				contentFontFace:'Times New Roman, Times, serif',
				contentFontSize:'12'
			  };
var webappMappings = {};
webappMappings['5000']={
webappId:    '5000',
documentId:  '1001',
internalId:  '',
customField: '20080824-204843'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '1073',
internalId:  '',
customField: '20080825-140414'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '1094',
internalId:  '',
customField: '20090129-141754'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '1115',
internalId:  '',
customField: '20090129-141815'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '1136',
internalId:  '',
customField: '20090129-141924'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '1157',
internalId:  '',
customField: '20080824-175815'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '20512',
internalId:  '',
customField: '20080826-000231'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '1199',
internalId:  '',
customField: '20090129-142126'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '10201',
internalId:  '',
customField: '20090129-142324'
};
webappMappings['1001']={
webappId:    '1001',
documentId:  '10201',
internalId:  'aars20in3hkh11b9cec7930',
customField: ''
};
webappMappings['1001']={
webappId:    '1001',
documentId:  '11401',
internalId:  'aars20in3hkh11b9cec7930',
customField: 'followUp'
};
webappMappings['5000']={
webappId:    '5000',
documentId:  '11401',
internalId:  '',
customField: '20080807-132808'
};
webappMappings['1006']={
webappId:    '1006',
documentId:  '1001',
internalId:  '1006',
customField: '1006'
};
var canonHostname = 'wsc01a.arsys.es';
var accountId     = 'AARS20IN3HKH';
var companyName   = 'TECSUB++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++TECNICA+SUBMARINA';
var htmlTitle	  = 'www.tecsub.es';
var metaKeywords  = 'padi+submarinismo+buceo+curso+majadahonda+las+rozas+pozuelo+madrid+espa%C3%B1a+ofertas+acuc+fedas+ssi+inmersion+seguros+buceo+tec+tecsub+pecios+cursos+open+water+diver+advanced+rescue+efr+divemaster+rescate+dive+master+primeros+auxilios+emergency+first+response+rcp+fotos+nacho+rojo+google+buscador+socio+asociado+federacion+apnea+natacion+examen+ofertas+jacket+bcd+mares+cressi+regulador+neopreno+gafas+mascara+octopus+segunda+etapa+primera+etapa+manometro+presion+bar+atm+boyle+tablas+descompresion+narcosis+camara+hiperbarica+hipervarica+diversion+deporte+mar+estrellas+peces+mero+morena+denton+lubina+traje+seco+5mm+6mm+7mm+8mm+excursion+islas+columbretes+altea+calpe+mediterraneo+ingles+italiano+compensar+vasalva+nitrox+helio+trimix+blog+temario+temas+workbook+work+dive+dicompresion+depth+meter+metro+metros+basico+marabierto+lago+rio+pantano+cuevas+espeleo+tecnico+navegacion+profunda+reconocimiento+especies+recuperacion+trabajos+subacuaticos+casco+antiguo+cascoantiguo+mar+rojo+los+roques+las+rotas+losroques+lasrotas+calahonda+almeria+villaricos+almu%C3%B1ecar+laherradura+la+herradura+malta+maldivas+thailand+enfoquesubmarino+egipt+truk+indonesio+jamaica+mexico+cozumel+rivera+maya+ballena+tiburon+shark+hotmail+mail+email+web+links+enlaces+facebook+sexunderwater+sex+underwater+cressi+mares+tecalp+video+mero+lubina+fish+diving+spain+holidays+diversion+apasionante+tecnico+emergencias+cruz+rojo+nadar+piscina+club+descanso+placer+nemrod+beuchat+nemo+suuntoo+atomic+';
var metaContents  = 'cursos+de+buceo+submarinismo+padi+en+madrid+denia+javea+y+mazarron.+Todos+los+niveles%2C+desde+open+water+diver+hasta+el+divemaster%2C+seguros%2C+viajes%2C+fotos%2C+ofertas+material+submarinismo%2C+salidas+de+fin+de+semana+y+semana+a+la+costa';
					                                                                    
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 */					                                                            

