/* [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','901',jdecode('Home'),jdecode(''), jdecode('%2F901.html'), 'true',[],'',''],
	['PAGE','14201',jdecode('News'),jdecode(''), jdecode('%2F14201.html'), 'true',[],'',''],
	['PAGE','25001',jdecode('Comments'),jdecode(''), jdecode('%2F25001.html'), 'true',[],'',''],
	['PAGE','7801',jdecode('Prices'),jdecode(''), jdecode('%2F7801.html'), 'true',[],'',''],
	['PAGE','1099',jdecode('Timetable'),jdecode(''), jdecode('%2F1099.html'), 'true',[],'',''],
	['PAGE','1141',jdecode('Contact'),jdecode(''), jdecode('%2F1141.html'), 'true',[],'',''],
	['PAGE','1162',jdecode('Seminars'),jdecode(''), jdecode('%2F1162.html'), 'true',[],'',''],
	['PAGE','28701',jdecode('HMA+Team'),jdecode(''), jdecode('%2F28701.html'), 'true',[],'',''],
	['PAGE','6301',jdecode('Mission+Statement'),jdecode(''), jdecode('%2F6301.html'), 'true',[],'',''],
	['PAGE','5501',jdecode('Guro+Rick%26%23x27%3Bs+Letter'),jdecode(''), jdecode('%2F5501.html'), 'true',[],'',''],
	['PAGE','18201',jdecode('Guro+Gary+Hoptroff'),jdecode(''), jdecode('%2F18201.html'), 'true',[],'',''],
	['PAGE','994',jdecode('Guro+David+Onuma'),jdecode(''), jdecode('%2F994.html'), 'true',[],'',''],
	['PAGE','72701',jdecode('Guro+Inosanto'),jdecode(''), jdecode('%2F72701.html'), 'true',[],'',''],
	['PAGE','973',jdecode('Guro+Rick+Faye'),jdecode(''), jdecode('%2F973.html'), 'true',[],'',''],
	['PAGE','82801',jdecode('HMA+Warriors'),jdecode(''), jdecode('%2F82801.html'), 'true',[],'',''],
	['PAGE','88401',jdecode('T.U.D.A'),jdecode(''), jdecode('%2F88401.html'), 'true',[],'',''],
	['PAGE','1015',jdecode('Jun+Fan+-+JKD'),jdecode(''), jdecode('%2F1015.html'), 'true',[],'',''],
	['PAGE','1036',jdecode('Kali+%28FMA%29'),jdecode(''), jdecode('%2F1036.html'), 'true',[],'',''],
	['PAGE','85101',jdecode('MKG+Drill+Rounds'),jdecode(''), jdecode('%2F85101.html'), 'true',[],'',''],
	['PAGE','1057',jdecode('Muay+Thai'),jdecode(''), jdecode('%2F1057.html'), 'true',[],'',''],
	['PAGE','69001',jdecode('BJJ'),jdecode(''), jdecode('%2F69001.html'), 'true',[],'',''],
	['PAGE','1078',jdecode('MMA+%28MKG%2FCSW%29'),jdecode(''), jdecode('%2F1078.html'), 'true',[],'',''],
	['PAGE','70027',jdecode('Tiny+Tigers'),jdecode(''), jdecode('%2F70027.html'), 'true',[],'',''],
	['PAGE','70001',jdecode('Thai+Tigers'),jdecode(''), jdecode('%2F70001.html'), 'true',[],'',''],
	['PAGE','34222',jdecode('Junior+Thai+boxing'),jdecode(''), jdecode('%2F34222.html'), 'true',[],'',''],
	['PAGE','80201',jdecode('Gallery'),jdecode(''), jdecode('%2F80201.html'), 'true',[],'',''],
	['PAGE','8601',jdecode('Directions'),jdecode(''), jdecode('%2F8601.html'), 'true',[],'',''],
	['PAGE','8701',jdecode('How+to+find+us'),jdecode(''), jdecode('%2F8701.html'), 'true',[],'',''],
	['PAGE','1183',jdecode('Links'),jdecode(''), jdecode('%2F1183.html'), 'true',[],'','']];
var siteelementCount=29;
theSitetree.topTemplateName='Circulation';
theSitetree.paletteFamily='FC2323';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10587';
theSitetree.graphicsetId='10561';
theSitetree.contentColor='DDDDDD';
theSitetree.contentBGColor='000000';
var localeDef={
  language: 'en',
  country: 'GB'
};
var prodDef={
  wl_name: 'easily_co_uk',
  product: 'WSCSYSSSSLY0XVD7'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Circulation',
				paletteFamily: 	'FC2323',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10587',
				graphicsetId: 	'10561',
				contentColor: 	'DDDDDD',
				contentBGColor: '000000',
				a_color: 		'FFFFFF',
				b_color: 		'FFFFFF',
				c_color: 		'FFFFFF',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '69001',
internalId:  '',
customField: '20100330-102826'
};
webappMappings['2001']=webappMappings['2001-location']={
webappId:    '2001',
documentId:  '8601',
internalId:  'location',
customField: 'language:en;country:GB;isIncluded:false;'
};
webappMappings['2002']=webappMappings['2002-routing']={
webappId:    '2002',
documentId:  '8701',
internalId:  'routing',
customField: 'en_GB'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '70027',
internalId:  '',
customField: '20100402-152649'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '72701',
internalId:  '',
customField: '20100725-221135'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '85101',
internalId:  '',
customField: '20110630-114619'
};
webappMappings['7060']=webappMappings['7060-7ac27d3205a1d2382929486fc5f6dc30']={
webappId:    '7060',
documentId:  '80201',
internalId:  '7ac27d3205a1d2382929486fc5f6dc30',
customField: 'language:en;country:GB;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '82801',
internalId:  '',
customField: '20111128-103929'
};
webappMappings['1501']=webappMappings['1501-895162']={
webappId:    '1501',
documentId:  '901',
internalId:  '895162',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8701',
internalId:  '',
customField: '20070228-181522'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '901',
internalId:  '',
customField: '20110630-113055'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14201',
internalId:  '',
customField: '20120110-121157'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7801',
internalId:  '',
customField: '20111128-103531'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1162',
internalId:  '',
customField: '20111027-095020'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25001',
internalId:  '',
customField: '20110503-134603'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6301',
internalId:  '',
customField: '20080912-170453'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5501',
internalId:  '',
customField: '20090505-172808'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '18201',
internalId:  '',
customField: '20111128-103746'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '973',
internalId:  '',
customField: '20100725-221038'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '994',
internalId:  '',
customField: '20100210-122930'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1015',
internalId:  '',
customField: '20110110-103924'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1036',
internalId:  '',
customField: '20110110-104025'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1057',
internalId:  '',
customField: '20120105-150346'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1078',
internalId:  '',
customField: '20100331-144351'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1099',
internalId:  '',
customField: '20111128-104117'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34222',
internalId:  '',
customField: '20080513-112309'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '80201',
internalId:  '',
customField: '20110109-221345'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1141',
internalId:  '',
customField: '20080826-150525'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1183',
internalId:  '',
customField: '20100511-085653'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8601',
internalId:  '',
customField: '20070228-181548'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28701',
internalId:  '',
customField: '20111128-103344'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '88401',
internalId:  '',
customField: '20120110-141829'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '901',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '70001',
internalId:  '',
customField: '20100402-153449'
};
var webAppHostname = 'cgi.easily.co.uk:80';
var canonHostname = 'coucm4all01.netbenefit.co.uk';
var accountId     = 'ANBT10INXX9E';
var companyName   = 'Hertfordshire+Martial+Arts';
var htmlTitle	  = '';
var metaKeywords  = 'Jun+Fan+Gung+Fu%2C+JKD%2C+Jeet+Kune+Do%2C+Barnet%2C+Hertfordshire%2C+Filipino+Martial+Arts%2C+Panantukan%2C+Muay+Thai%2C+Grappling%2C+Self+Defence%2C+martial+arts%2C+ladies+only+classes%2C+childrens+martial+arts%2C+Gary+Hoptroff%2C+kids+martial+arts%2C+martial+arts+equipment%2C+Rick+Faye%2C+David+Onuma%2C+Kali%2C+Minnesota+Kali+Group%2C+Combined+Fighting+Systems%2C+MKG%2C+CFS%2C+BJJ%2C+kids+classes%2C+private+training%2C+seminars%2C+Dan+Inosanto';
var metaContents  = 'Full+Time+Martial+Arts+Gym+in+Barnet%2C+Jeet+Kune+Do%2C+Filipino+Martial+Arts%2C+Muay+Thai%2C+Grappling%2C+MMA%2C+BJJ+%26+Childrens+classes';
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();
};

