/* [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','4476',jdecode('Home'),jdecode(''),'/4476.html','true',[],'',''],
	['PAGE','4533',jdecode('%C2%BFQui%C3%A9nes+Somos%3F'),jdecode(''),'/4533.html','true',[],'',''],
	['PAGE','23056',jdecode('%C2%BFQu%C3%A9+hacemos%3F'),jdecode(''),'/23056.html','true',[],'',''],
	['PAGE','13101',jdecode('Servicios'),jdecode(''),'/13101.html','true',[],'',''],
	['PAGE','41423',jdecode('VENTA+CASAS'),jdecode(''),'/41423/index.html','true',[ 
		['PAGE','41744',jdecode('Coyoac%C3%A1n'),jdecode(''),'/41423/41744.html','true',[],'',''],
		['PAGE','69723',jdecode('Tequesquitengo+%28Morelos%29'),jdecode(''),'/41423/69723.html','true',[],'',''],
		['PAGE','78423',jdecode('Nepentla%2C+Estado+de+M%C3%A9xico'),jdecode(''),'/41423/78423.html','true',[],'',''],
		['PAGE','82823',jdecode('Tepalcates'),jdecode(''),'/41423/82823.html','true',[],'',''],
		['PAGE','76023',jdecode('Fraccionamiento+Lomas+de+Lindavista'),jdecode(''),'/41423/76023.html','true',[],'',''],
		['PAGE','82723',jdecode('Bosques+de+las+Lomas'),jdecode(''),'/41423/82723.html','true',[],'',''],
		['PAGE','93023',jdecode('Moctezuma+2%C2%AA+secci%C3%B3n'),jdecode(''),'/41423/93023.html','true',[],'',''],
		['PAGE','98823',jdecode('Bosques+del+Alba+II'),jdecode(''),'/41423/98823.html','true',[],'',''],
		['PAGE','102223',jdecode('Haciendas+de+Coyoacan'),jdecode(''),'/41423/102223.html','true',[],'',''],
		['PAGE','109623',jdecode('Cuernavaca'),jdecode(''),'/41423/109623.html','true',[],'','']
	],'',''],
	['PAGE','43823',jdecode('VENTA+DEPARTAMENTOS'),jdecode(''),'/43823/index.html','true',[ 
		['PAGE','55723',jdecode('Col.+Ju%C3%A1rez+'),jdecode(''),'/43823/55723.html','true',[],'',''],
		['PAGE','66823',jdecode('Col.+Bosque+de+Arag%C3%B3n'),jdecode(''),'/43823/66823.html','true',[],'',''],
		['PAGE','42223',jdecode('Col.+Del+Valle'),jdecode(''),'/43823/42223.html','true',[],'',''],
		['PAGE','83123',jdecode('Del+Valle'),jdecode(''),'/43823/83123.html','true',[],'',''],
		['PAGE','87923',jdecode('Lomas+Verdes+1%C2%AA+Secci%C3%B3n'),jdecode(''),'/43823/87923.html','true',[],'',''],
		['PAGE','87965',jdecode('Asturias'),jdecode(''),'/43823/87965.html','true',[],'',''],
		['PAGE','94023',jdecode('Narvarte'),jdecode(''),'/43823/94023.html','true',[],'',''],
		['PAGE','109023',jdecode('Moderna'),jdecode(''),'/43823/109023.html','true',[],'','']
	],'',''],
	['PAGE','43223',jdecode('VENTA+TERRENOS'),jdecode(''),'/43223/index.html','true',[ 
		['PAGE','86923',jdecode('Morelos'),jdecode(''),'/43223/86923.html','true',[],'',''],
		['PAGE','97823',jdecode('Col.+Centro'),jdecode(''),'/43223/97823.html','true',[],'',''],
		['PAGE','106123',jdecode('Ozumba+'),jdecode(''),'/43223/106123.html','true',[],'','']
	],'',''],
	['PAGE','42723',jdecode('RENTA+CASAS'),jdecode(''),'/42723/index.html','true',[ 
		['PAGE','64023',jdecode('Cuernavaca'),jdecode(''),'/42723/64023.html','true',[],'','']
	],'',''],
	['PAGE','42923',jdecode('RENTA+DEPARTAMENTOS'),jdecode(''),'/42923.html','true',[],'',''],
	['PAGE','43123',jdecode('RENTA++LOCALES+COMERCIALES'),jdecode(''),'/43123/index.html','true',[ 
		['PAGE','80923',jdecode('Anahuac'),jdecode(''),'/43123/80923.html','true',[],'','']
	],'',''],
	['PAGE','4614',jdecode('Cont%C3%A1ctenos'),jdecode(''),'/4614.html','true',[],'','']];
var siteelementCount=34;
theSitetree.topTemplateName='Global';
theSitetree.paletteFamily='0E6C84';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='86';
theSitetree.graphicsetId='106';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FFFFFF';
var localeDef={
  language: 'es',
  country: 'ES'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Global',
				paletteFamily: 	'0E6C84',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'86',
				graphicsetId: 	'106',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				a_color: 		'0E6C84',
				b_color: 		'FFE151',
				c_color: 		'000000',
				d_color: 		'E6EEF1',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'false',
				contentFontFace:'Times New Roman, Times, serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '4476',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4476',
internalId:  '',
customField: '20060713-100736'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102223',
internalId:  '',
customField: '20100706-162329'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '106123',
internalId:  '',
customField: '20100715-154707'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '41423',
internalId:  '',
customField: '20090601-183546'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4533',
internalId:  '',
customField: '20090522-194750'
};
webappMappings['7008']=webappMappings['7008-7084']={
webappId:    '7008',
documentId:  '4614',
internalId:  '7084',
customField: 'language:es;country:ES;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '64023',
internalId:  '',
customField: '20090722-181058'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4614',
internalId:  '',
customField: '20090310-205810'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '109023',
internalId:  '',
customField: '20100805-184625'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '76023',
internalId:  '',
customField: '20091120-184026'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '41744',
internalId:  '',
customField: '20090708-184154'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23056',
internalId:  '',
customField: '20060830-134716'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13101',
internalId:  '',
customField: '20060712-130201'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '78423',
internalId:  '',
customField: '20091124-170335'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '87965',
internalId:  '',
customField: '20100318-190650'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '82723',
internalId:  '',
customField: '20100223-191403'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43823',
internalId:  '',
customField: '20100318-184811'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '42223',
internalId:  '',
customField: '20090601-190133'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '66823',
internalId:  '',
customField: '20090803-182551'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '69723',
internalId:  '',
customField: '20100304-175732'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '80923',
internalId:  '',
customField: '20091125-173344'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '82823',
internalId:  '',
customField: '20100223-190809'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '97823',
internalId:  '',
customField: '20100623-165218'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43223',
internalId:  '',
customField: '20090310-203230'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '109623',
internalId:  '',
customField: '20100804-161924'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '86923',
internalId:  '',
customField: '20100623-152453'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '42723',
internalId:  '',
customField: '20090310-202541'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '94023',
internalId:  '',
customField: '20100601-181754'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '42923',
internalId:  '',
customField: '20090930-182431'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '87923',
internalId:  '',
customField: '20100318-190342'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '93023',
internalId:  '',
customField: '20100528-184457'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43123',
internalId:  '',
customField: '20090310-203150'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '98823',
internalId:  '',
customField: '20100629-165725'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '83123',
internalId:  '',
customField: '20100511-183403'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '55723',
internalId:  '',
customField: '20090625-170721'
};
var canonHostname = 'diywk00.verio.stngva01.us.diy-servers.net';
var accountId     = 'AVEC10INXS8A';
var companyName   = 'Promotora++Inmobiliaria+California';
var htmlTitle	  = 'Promotora+Inmobiliaria+California';
var metaKeywords  = 'RENTA%2C+VENTA%2C+AVALUOS+BANCARIOS+Y+COMERCIALES%2C+CREDITOS+BANCARIOS%2C+SUCESIONES+TESTAMENTARIAS%2C+REMODELACION+DE+INMUEBLES%2C+REGIMEN+DE+CONDOMINIO';
var metaContents  = 'RENTA%2C+VENTA%2C+AVALUOS+BANCARIOS+Y+COMERCIALES%2C+CREDITOS+BANCARIOS%2C+SUCESIONES+TESTAMENTARIAS%2C+REMODELACION+DE+INMUEBLES%2C+REGIMEN+DE+CONDOMINIO';
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();
};
