/* [nodename, id, name, navigationtext, href, isnavigation, childs[], templatename] */

if (typeof(decodeURIComponent) == 'undefined') {
  decodeURIComponent = function(s) {
    return unescape(s);
  }
}

function jdecode(s) {
    s = s.replace(/\+/g, "%20")
    return decodeURIComponent(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 POS_TARGET=8;
var theSitetree=[ 
	['PAGE','4478',jdecode('Inicio'),jdecode(''),'/4478.html','true',[],'',''],
	['PAGE','141012',jdecode('Cat%C3%A1logo'),jdecode(''),'/141012/index.html','true',[ 
		['PAGE','122112',jdecode('General+T%C3%ADtulo'),jdecode(''),'/141012/122112.html','true',[],'',''],
		['PAGE','4616',jdecode('General+Autor'),jdecode(''),'/141012/4616.html','true',[],'','']
	],'',''],
	['PAGE','12101',jdecode('Distribuidoras'),jdecode(''),'/12101.html','true',[],'',''],
	['PAGE','4751',jdecode('Env%C3%ADo+de+originales'),jdecode(''),'/4751.html','true',[],'',''],
	['PAGE','86912',jdecode('Concursos+Anroart'),jdecode(''),'/86912/index.html','true',[ 
		['PAGE','117612',jdecode('Canarias+escribe+Canarias'),jdecode(''),'/86912/117612.html','true',[],'',''],
		['PAGE','86933',jdecode('Relato+Juvenil+Fuertev.'),jdecode(''),'/86912/86933.html','true',[],'',''],
		['PAGE','108612',jdecode('Premio+de+Teatro'),jdecode(''),'/86912/108612.html','true',[],'','']
	],'',''],
	['PAGE','114412',jdecode('Taller+de+Literatura'),jdecode(''),'/114412/index.html','true',[ 
		['PAGE','114433',jdecode('Inscripci%C3%B3n'),jdecode(''),'/114412/114433/index.html','true',[ 
			['PAGE','115212',jdecode('Inscripcci%C3%B3n+%28follow+up+page%29'),jdecode(''),'/114412/114433/115212.html','false',[],'','']
		],'','']
	],'',''],
	['PAGE','85012',jdecode('Cursos+literarios'),jdecode(''),'/85012/index.html','true',[ 
		['PAGE','4832',jdecode('Curso+Ciudarte'),jdecode(''),'/85012/4832.html','true',[],'',''],
		['PAGE','108633',jdecode('Factor%C3%ADa+de+ficciones'),jdecode(''),'/85012/108633.html','true',[],'',''],
		['PAGE','13701',jdecode('Curso+de+Creaci%C3%B3n+Literaria+%28follow+up+page%29'),jdecode(''),'/85012/13701.html','false',[],'','']
	],'',''],
	['PAGE','10401',jdecode('Foros+de+debate'),jdecode(''),'/10401/index.html','true',[ 
		['PAGE','27706',jdecode('Libro+de+visitas'),jdecode(''),'/10401/27706.html','true',[],'',''],
		['PAGE','27701',jdecode('Leer+el+libro+de+Visitas'),jdecode(''),'/10401/27701.html','false',[],'',''],
		['PAGE','47001',jdecode('Nota+de+la+editorial'),jdecode(''),'/10401/47001.html','true',[],'','']
	],'',''],
	['PAGE','101312',jdecode('%C3%81rea+de+juegos'),jdecode(''),'/101312/index.html','true',[ 
		['PAGE','102212',jdecode('Speartoss'),jdecode(''),'/101312/102212.html','true',[],'',''],
		['PAGE','102233',jdecode('F%C3%BAtbol'),jdecode(''),'/101312/102233.html','true',[],'',''],
		['PAGE','102254',jdecode('Diamonds'),jdecode(''),'/101312/102254.html','true',[],'',''],
		['PAGE','102275',jdecode('Rock+Rocket'),jdecode(''),'/101312/102275.html','true',[],'',''],
		['PAGE','102296',jdecode('Invaders'),jdecode(''),'/101312/102296.html','true',[],'','']
	],'',''],
	['PAGE','4859',jdecode('Nuestras+direcciones'),jdecode(''),'/4859/index.html','true',[ 
		['PAGE','28601',jdecode('C%C3%B3mo+encontrarnos'),jdecode(''),'/4859/28601.html','true',[],'',''],
		['PAGE','9901',jdecode('Mapa+de+acceso'),jdecode(''),'/4859/9901.html','true',[],'','']
	],'',''],
	['PAGE','24701',jdecode('Protecci%C3%B3n+de+datos'),jdecode(''),'/24701.html','true',[],'',''],
	['PAGE','4886',jdecode('%C2%BFQui%C3%A9nes+somos%3F'),jdecode(''),'/4886/index.html','true',[ 
		['PAGE','40501',jdecode('Pertenecemos+a'),jdecode(''),'/4886/40501.html','true',[],'','']
	],'','']];
var siteelementCount=33;
theSitetree.topTemplateName='Liveliness';
theSitetree.paletteFamily='BE9A5B';
theSitetree.keyvisualId='3267';
theSitetree.keyvisualName='kv_3267.jpg';
theSitetree.fontsetId='10424';
theSitetree.graphicsetId='10735';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='000000';
var localeDef={
  language: 'es',
  country: 'ES'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Liveliness',
				paletteFamily: 	'BE9A5B',
				keyvisualId: 	'3267',
				keyvisualName: 	'kv_3267.jpg',
				fontsetId: 		'10424',
				graphicsetId: 	'10735',
				contentColor: 	'FFFFFF',
				contentBGColor: '000000',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'BE9A5B',
				e_color: 		'BCBCBC',
				f_color: 		'737373',
				hasCustomLogo: 	'true',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'true'
			  };
var webappMappings = {};
webappMappings['7008']=webappMappings['7008-8042']={
webappId:    '7008',
documentId:  '4832',
internalId:  '8042',
customField: 'language:es;country:ES;'
};
webappMappings['2001']=webappMappings['2001-location']={
webappId:    '2001',
documentId:  '9901',
internalId:  'location',
customField: 'language:es;country:ES;isIncluded:false;'
};
webappMappings['1003']=webappMappings['1003-aas010inepze112d9e9a849']={
webappId:    '1003',
documentId:  '10401',
internalId:  'aas010inepze112d9e9a849',
customField: 'es:ES:'
};
webappMappings['1501']=webappMappings['1501-3635350']={
webappId:    '1501',
documentId:  '4478',
internalId:  '3635350',
customField: '1501'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '4478',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '141012',
internalId:  '',
customField: '20100315-121601'
};
webappMappings['7008']=webappMappings['7008-8063']={
webappId:    '7008',
documentId:  '141012',
internalId:  '8063',
customField: 'language:es;country:ES;'
};
webappMappings['7008']=webappMappings['7008-8044']={
webappId:    '7008',
documentId:  '114433',
internalId:  '8044',
customField: 'language:es;country:ES;'
};
webappMappings['1002']=webappMappings['1002-27706aas010inepze']={
webappId:    '1002',
documentId:  '27706',
internalId:  '27706aas010inepze',
customField: 'icq=false'
};
webappMappings['2002']=webappMappings['2002-routing']={
webappId:    '2002',
documentId:  '28601',
internalId:  'routing',
customField: 'es_ES'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4478',
internalId:  '',
customField: '20100707-163227'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '122112',
internalId:  '',
customField: '20100310-223613'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4616',
internalId:  '',
customField: '20090402-180605'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27701',
internalId:  '',
customField: '20070616-052340'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '115212',
internalId:  '',
customField: '20090917-185107'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '117612',
internalId:  '',
customField: '20100416-023250'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102212',
internalId:  '',
customField: '20080919-191326'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '114412',
internalId:  '',
customField: '20090923-201102'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '114433',
internalId:  '',
customField: '20090917-185218'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '12101',
internalId:  '',
customField: '20100315-123324'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4751',
internalId:  '',
customField: '20100519-211806'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4832',
internalId:  '',
customField: '20080225-125908'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13701',
internalId:  '',
customField: '20070530-011849'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10401',
internalId:  '',
customField: '20070714-023518'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27706',
internalId:  '',
customField: '20070616-052015'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '47001',
internalId:  '',
customField: '20070714-023634'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4859',
internalId:  '',
customField: '20090111-004404'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28601',
internalId:  '',
customField: '20070616-193323'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9901',
internalId:  '',
customField: '20070902-233923'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '24701',
internalId:  '',
customField: '20100310-230304'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4886',
internalId:  '',
customField: '20090304-104217'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '40501',
internalId:  '',
customField: '20070627-041653'
};
webappMappings['7005']=webappMappings['7005-61']={
webappId:    '7005',
documentId:  '4478',
internalId:  '61',
customField: 'language:es;country:ES;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '85012',
internalId:  '',
customField: '20090917-183412'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '101312',
internalId:  '',
customField: '20080920-025015'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '86912',
internalId:  '',
customField: '20100416-022947'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '86933',
internalId:  '',
customField: '20080229-220628'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102233',
internalId:  '',
customField: '20080919-191607'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102254',
internalId:  '',
customField: '20080919-191637'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102275',
internalId:  '',
customField: '20080919-191732'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102296',
internalId:  '',
customField: '20080919-191806'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '108612',
internalId:  '',
customField: '20090123-125950'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '108633',
internalId:  '',
customField: '20090304-115939'
};
var canonHostname = 'llwc535.servidoresdns.net';
var accountId     = 'Aas010INEPZE';
var companyName   = 'ANROART+EDICIONES%2C+SL';
var htmlTitle	  = 'Anroart+Ediciones';
var metaKeywords  = 'Canarias+historia+geograf%C3%ADa+editorial+novela+poes%C3%ADa+Canary+book+libro+archiv%C3%ADstica+Anroart+cultura+canaria+autor+econom%C3%ADa+derecho+lengua+paleografia+fon%EF%BF%BDtica+religi%EF%BF%BD';
var metaContents  = 'La+editorial+canaria+abierta+al+mundo';
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;
};

theSitetree.getByXx = function(lookup, xx, ar) {
    if (typeof(ar) == 'undefined'){
    	ar = this;
    }
    for (var i=0; i < ar.length; i++) {
        if (ar[i][xx] == lookup){
        	return ar[i];
        }
        if (ar[i][POS_CHILDS].length > 0) {
        	var result=this.getByXx(lookup, xx, ar[i][POS_CHILDS]);
            if (result != null){
                return result;
               }
        }
    }
    return null;
};

function gotoPage(lookup) {
	if(__path_prefix__ == "/servlet/CMServeRES" && typeof (changePage) == 'function'){
		changePage(lookup);
		return;
	}
	var page = theSitetree.getHREF(lookup);
	if (!page) {
		var testFor = [ POS_NAME, POS_NAVIGATIONTEXT ];
		for (var i=0 ; i < testFor.length ; i++) {
			var p = theSitetree.getByXx(lookup, testFor[i]);
			if (p != null) {
				page = p[POS_HREF];
				break;
			}
		}
	}
	document.location.href = (new URL(__path_prefix__ + page, true, true)).toString();
};
