/* [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','2101',jdecode('Home'),jdecode(''),'/2101.html','true',[],'',''],
	['PAGE','2152',jdecode('About+your+English+classes'),jdecode(''),'/2152.html','true',[],'',''],
	['PAGE','2215',jdecode('Service'),jdecode(''),'/2215.html','true',[],'',''],
	['PAGE','2236',jdecode('Products'),jdecode(''),'/2236.html','true',[],'',''],
	['PAGE','11701',jdecode('Contact+and+Tuition'),jdecode(''),'/11701.html','true',[],'','']];
var siteelementCount=5;
theSitetree.topTemplateName='Displace';
theSitetree.paletteFamily='CFCFCF';
theSitetree.keyvisualId='11075';
theSitetree.keyvisualName='kv_11075.jpg';
theSitetree.fontsetId='31958';
theSitetree.graphicsetId='13799';
theSitetree.contentColor='342500';
theSitetree.contentBGColor='CFCFCF';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Displace',
				paletteFamily: 	'CFCFCF',
				keyvisualId: 	'11075',
				keyvisualName: 	'kv_11075.jpg',
				fontsetId: 		'31958',
				graphicsetId: 	'13799',
				contentColor: 	'342500',
				contentBGColor: 'CFCFCF',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'false',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'true'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2101',
internalId:  '',
customField: '20110814-153810'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2215',
internalId:  '',
customField: '20110814-154205'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2152',
internalId:  '',
customField: '20110813-115904'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2236',
internalId:  '',
customField: '20110813-115509'
};
webappMappings['5001']=webappMappings['5001-']={
webappId:    '5001',
documentId:  '2101',
internalId:  '',
customField: 'language:en;country:US;'
};
webappMappings['5001']=webappMappings['5001-']={
webappId:    '5001',
documentId:  '2152',
internalId:  '',
customField: 'language:en;country:US;'
};
webappMappings['7008']=webappMappings['7008-319']={
webappId:    '7008',
documentId:  '11701',
internalId:  '319',
customField: 'language:en;country:US;'
};
webappMappings['5001']=webappMappings['5001-']={
webappId:    '5001',
documentId:  '2215',
internalId:  '',
customField: 'language:en;country:US;'
};
webappMappings['5001']=webappMappings['5001-']={
webappId:    '5001',
documentId:  '2236',
internalId:  '',
customField: 'language:en;country:US;'
};
webappMappings['5001']=webappMappings['5001-']={
webappId:    '5001',
documentId:  '11701',
internalId:  '',
customField: 'language:en;country:US;'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '2101',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '11701',
internalId:  '',
customField: '20110809-191031'
};
var canonHostname = 'cm4all01.west-datacenter.net';
var accountId     = 'AWH030IN27E1';
var companyName   = 'Weston+English+2009%E2%84%A2';
var htmlTitle	  = 'Weston+English+2009%E2%84%A2+-+ESL+and+Accent+Reduction';
var metaKeywords  = 'TOEFL%2C+Berlitz%2C+Spanish%2C+inglesa%2C+ingles%2C+English%2C+language+instruction%2CCross+Cultural+Training%2COnline+language+instruction%2CStudy+Abroad%2CInternational+Language+School%2C+florida+language+school%2C+adult+education%2C+us+citizenship+preparation%2C+English+as+a+second+language%2C+ESL%2C+ESOL%2C+Language+center%2C+private+language+instruction%2C+Inlingua%2C+native+teachers%2C+Unique+Method%2C+Weston%2C+Weston+language+school%2C+weston+language+center%2C+language+training%2C+1516+Weston+Road%2C+Weston+language+schools%2C+Weston+language+schools+english+classes%2C+english+classes%2C++language+assessment%2C+Ingles+como+segunda+lengua%2C++language+assessment.+Ingles+como+segunda+lengua%2C+weston+ingles%2C+ingles+weston%2C+lingua%2Cenglish+as+a+2nd+language%2C+Ingles%2C+Kenneth+Beare%2C+Ingles+como+segunda+lengua%2C+International+English%2C+English+courses%2C+english+classes%2C+english+course%2C+english+class%2C+Miami%2C++English+courses+weston%2C+english+classes+weston%2C+english+course+weston%2C+english+class+weston%2C+Weston+English+courses%2CWeston+english+classes%2C+Weston+english+course%2C+Weston+english+class%2CBusiness+english%2C+business+curriculum%2Cwestonenglish2009%2C+weston+english+2009%2C+corporate+business+english%2C+weston+fl%2C+english+weston+fl%2C+esl+weston+fl%2C+esol+weston+fl%2C+accent+reduction+training%2C+accent+reduction+fl%2C+accent+reduction+weston+fl%2C+weston+florida%2C+weston+florida+language+school%2C+english+weston%2C+accent+reduction%2C+Videos+for+accent+reduction%2C+accent+reduction+institute%2C+american+accent+training%2C+accent+reduction+-+tip%2C+accent+reduction+-+wikipedia%2C+Learning+american+english%2C+native+speaker%2C+foreign+accent+reduction%2C+online+accent+training%2C+accent+reduction+course%2C+accent+reduction+courses%2C+accent+classes%2C+executive+coach%2C+executive+coach+accent+reduction%2C+accent+reduction+Miami%2C+accent+reduction+public+speaking%2C+accent+reduction+Weston%2C+accent+reduction+Weston+florida%2C+American+Speech-Language-Hearing+Association%2C+Spanish%2C+Language+School+in+weston%2C+Learn+a+New+Language%2C+high+quality%2C+high+quality+english%2C++Weston+Hills+Country+Club%2C++TOEFL+iBT%2C+TOEIC%2C+SAT%2C+GMAT%2C+GRE%2C+and+LSAT%2C+Tequesta+Indian%2C++Tequesta%2C+inlingua-if%2C+find+english+classes%2C+weston+english%2C+Clases+de+Ingles+en+weston%2C+Cursos+de+Ingles+en+weston%2C+Clases+de+Ingles%2C+Cursos+de+Ingles%2C+Clase+de+Ingles+en+weston%2C+Curso+de+Ingles+en+weston%2C+Clase+de+Ingles%2C+Curso+de+Ingles%2C+ingles+weston%2C+weston+ingles+++';
var metaContents  = 'Weston+English+2009%E2%84%A2+and+Accent+Reduction%3A+Teaching+English+as+a+second+language+%28ESL%29+and+accent+reduction+in+Weston%2C+FL+-+Ingles+como+segunda+lengua+-+Acreditado+programa+estructurado+del+lenguaje+y+curriculum+empresarial.+WestonEnglish2009%E2%84%A2+ESL+offers+the+worlds+leading+text+books+and+conversational+English+for+learners+and+teachers+of+English+-+taken+by+over+2+million+people+in+130+countries';
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();
};

