/* [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','401',jdecode('Home'),jdecode(''),'/401.html','true',[],'',''],
	['PAGE','452',jdecode('About+us'),jdecode(''),'/452/index.html','true',[ 
		['PAGE','473',jdecode('How+to+find+us'),jdecode(''),'/452/473.html','true',[],'',''],
		['PAGE','494',jdecode('Our+team'),jdecode(''),'/452/494.html','true',[],'',''],
		['PAGE','515',jdecode('Opening+Hours'),jdecode(''),'/452/515.html','true',[],'','']
	],'',''],
	['PAGE','16701',jdecode('Price+List'),jdecode(''),'/16701.html','true',[],'',''],
	['PAGE','10201',jdecode('News+%26+Offers'),jdecode(''),'/10201.html','true',[],'',''],
	['PAGE','557',jdecode('IPL+Hair+Removal'),jdecode(''),'/557/index.html','true',[ 
		['PAGE','10222',jdecode('Prices'),jdecode(''),'/557/10222.html','true',[],'','']
	],'',''],
	['PAGE','578',jdecode('Other+IPL+Treatments'),jdecode(''),'/578/index.html','true',[ 
		['PAGE','10243',jdecode('Prices'),jdecode(''),'/578/10243.html','true',[],'','']
	],'',''],
	['PAGE','23001',jdecode('Colon+Hydrotherapy'),jdecode(''),'/23001.html','true',[],'',''],
	['PAGE','599',jdecode('Beauty+Treatments'),jdecode(''),'/599/index.html','true',[ 
		['PAGE','10264',jdecode('Prices'),jdecode(''),'/599/10264.html','true',[],'','']
	],'',''],
	['PAGE','29301',jdecode('Laser+Lipo'),jdecode(''),'/29301.html','true',[],'',''],
	['PAGE','31601',jdecode('Nutrition+Services'),jdecode(''),'/31601.html','true',[],'',''],
	['PAGE','620',jdecode('Aqua+Detox'),jdecode(''),'/620.html','true',[],'',''],
	['PAGE','641',jdecode('Cognitive+Hypnotherapy'),jdecode(''),'/641.html','true',[],'',''],
	['PAGE','662',jdecode('Hopi+Ear+Candle'),jdecode(''),'/662.html','true',[],'',''],
	['PAGE','683',jdecode('Body+Work'),jdecode(''),'/683/index.html','true',[ 
		['PAGE','10285',jdecode('Prices'),jdecode(''),'/683/10285.html','true',[],'','']
	],'',''],
	['PAGE','725',jdecode('Dermal+Filler+Injections'),jdecode(''),'/725.html','true',[],'',''],
	['PAGE','746',jdecode('Skin+Care+Products'),jdecode(''),'/746.html','true',[],'',''],
	['PAGE','788',jdecode('Interesting+Links'),jdecode(''),'/788.html','true',[],'','']];
var siteelementCount=24;
theSitetree.topTemplateName='Medium';
theSitetree.paletteFamily='F8F2E6';
theSitetree.keyvisualId='2181';
theSitetree.keyvisualName='wellness.jpg';
theSitetree.fontsetId='360';
theSitetree.graphicsetId='410';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='F8F2E6';
var localeDef={
  language: 'en',
  country: 'GB'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Medium',
				paletteFamily: 	'F8F2E6',
				keyvisualId: 	'2181',
				keyvisualName: 	'wellness.jpg',
				fontsetId: 		'360',
				graphicsetId: 	'410',
				contentColor: 	'000000',
				contentBGColor: 'F8F2E6',
				a_color: 		'F8F2E6',
				b_color: 		'8EBFC6',
				c_color: 		'FFFFFF',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'true',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '401',
internalId:  '',
customField: '20081128-110900'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10222',
internalId:  '',
customField: '20080717-165856'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '452',
internalId:  '',
customField: '20080415-143723'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '473',
internalId:  '',
customField: '20080229-153759'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '494',
internalId:  '',
customField: '20081117-150619'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '515',
internalId:  '',
customField: '20080415-143543'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '557',
internalId:  '',
customField: '20080229-153930'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '578',
internalId:  '',
customField: '20080403-155224'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '599',
internalId:  '',
customField: '20081007-131907'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '620',
internalId:  '',
customField: '20071106-225949'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '641',
internalId:  '',
customField: '20081117-151842'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '662',
internalId:  '',
customField: '20071106-230049'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '683',
internalId:  '',
customField: '20080408-123417'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29301',
internalId:  '',
customField: '20080723-152729'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '725',
internalId:  '',
customField: '20080403-160133'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '746',
internalId:  '',
customField: '20071106-202700'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10201',
internalId:  '',
customField: '20100102-140143'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '788',
internalId:  '',
customField: '20080229-154300'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10243',
internalId:  '',
customField: '20081007-131426'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10264',
internalId:  '',
customField: '20081007-131943'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10285',
internalId:  '',
customField: '20071116-115919'
};
webappMappings['1501']=webappMappings['1501-3731956']={
webappId:    '1501',
documentId:  '401',
internalId:  '3731956',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '16701',
internalId:  '',
customField: '20080723-150613'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '401',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31601',
internalId:  '',
customField: '20081128-112218'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23001',
internalId:  '',
customField: '20081007-131537'
};
var canonHostname = 'coucm4all01.netbenefit.co.uk';
var accountId     = 'ANBT10IN2DG6';
var companyName   = 'PH7';
var htmlTitle	  = 'PH7+London';
var metaKeywords  = 'Laser+hair+removal%2C+IPL%2C+thread+veins%2C+pigmentation%2C+rejuvenation%2C+acne%2C+environ%2C+restylane%2C+massage%2C+manicure%2C+pedicure%2C+manicure%2C+aquadetox%2C+hopi+ear+candle%2C+aromatherapy%2C+holistic%2C+vitamin%2C+ellipse%2C++hypnotherapy%2C+waxing%2C+NLP%2C+ph7%2C+clinic%2C+beauty%2C+wimbledon%2C+south+london%2C+laser+lipo%2C+liposuction%2C+hair+removal%2C+colonics%2C+colon+hydrotherapy%2C+colonic+irrigation';
var metaContents  = 'Nurse+led+specialist+treatment+centre+for+hair+removal%2C+thread+veins%2C+pigmentation%2C+acne%2C+and+rejuvenation%2C+catered+to+your+specific+needs.+A+wide+range+of+Beauty+treatments+also+available.++';
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();
};
