/* [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','1301',jdecode('Home'),jdecode(''),'/1301/index.html','true',[ 
		['PAGE','1352',jdecode('Home-+English'),jdecode(''),'/1301/1352.html','true',[],'','']
	],'',''],
	['PAGE','1394',jdecode('Latest+news'),jdecode(''),'/1394.html','true',[],'',''],
	['PAGE','1436',jdecode('Luach'),jdecode(''),'/1436.html','true',[],'',''],
	['PAGE','1457',jdecode('Chagim'),jdecode(''),'/1457.html','true',[],'',''],
	['PAGE','1478',jdecode('Smanej+Tfila'),jdecode(''),'/1478/index.html','true',[ 
		['PAGE','34701',jdecode('Chagim+%2B+Selichot'),jdecode(''),'/1478/34701.html','true',[],'','']
	],'',''],
	['PAGE','1499',jdecode('Spenden%2FDonations'),jdecode(''),'/1499.html','true',[],'',''],
	['PAGE','1520',jdecode('Feedback'),jdecode(''),'/1520/index.html','true',[ 
		['PAGE','15601',jdecode('Feedback+%28follow+up+page%29'),jdecode(''),'/1520/15601.html','false',[],'','']
	],'',''],
	['PAGE','1541',jdecode('Kiddush-Hilfe'),jdecode(''),'/1541.html','true',[],'',''],
	['PAGE','20601',jdecode('Schiurim'),jdecode(''),'/20601.html','true',[],'',''],
	['PAGE','1562',jdecode('Links'),jdecode(''),'/1562.html','true',[],'',''],
	['PAGE','31401',jdecode('protokoll'),jdecode(''),'/31401.html','false',[],'',''],
	['PAGE','15801',jdecode('Kontakt'),jdecode(''),'/15801.html','true',[],'',''],
	['PAGE','14306',jdecode('Guestbook'),jdecode(''),'/14306/index.html','true',[ 
		['PAGE','14301',jdecode('Read+Guestbook'),jdecode(''),'/14306/14301.html','false',[],'','']
	],'','']];
var siteelementCount=17;
theSitetree.topTemplateName='Seifenblase';
theSitetree.paletteFamily='C8E2FF';
theSitetree.keyvisualId='2357';
theSitetree.keyvisualName='event-agentur4.jpg';
theSitetree.fontsetId='379';
theSitetree.graphicsetId='427';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FFFFFF';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Seifenblase',
				paletteFamily: 	'C8E2FF',
				keyvisualId: 	'2357',
				keyvisualName: 	'event-agentur4.jpg',
				fontsetId: 		'379',
				graphicsetId: 	'427',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				a_color: 		'FFFFFF',
				b_color: 		'FFFFFF',
				c_color: 		'FFFFFF',
				d_color: 		'6666CC',
				e_color: 		'3333CC',
				f_color: 		'9999CC',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '1301',
internalId:  '1006',
customField: '1006'
};
webappMappings['1501']=webappMappings['1501-10757757']={
webappId:    '1501',
documentId:  '1301',
internalId:  '10757757',
customField: '1501'
};
webappMappings['1002']=webappMappings['1002-14306aen010invcv2']={
webappId:    '1002',
documentId:  '14306',
internalId:  '14306aen010invcv2',
customField: 'icq=false'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1301',
internalId:  '',
customField: '20080212-075046'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1352',
internalId:  '',
customField: '20071028-015219'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1394',
internalId:  '',
customField: '20090807-055308'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1436',
internalId:  '',
customField: '20071021-075038'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1457',
internalId:  '',
customField: '20071022-161511'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1478',
internalId:  '',
customField: '20100122-054736'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31401',
internalId:  '',
customField: '20090521-031610'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1499',
internalId:  '',
customField: '20090929-023314'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1520',
internalId:  '',
customField: '20071021-062839'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15601',
internalId:  '',
customField: '20071021-062947'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1541',
internalId:  '',
customField: '20090717-011137'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '20601',
internalId:  '',
customField: '20071028-014152'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1562',
internalId:  '',
customField: '20071024-131544'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34701',
internalId:  '',
customField: '20090917-021357'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15801',
internalId:  '',
customField: '20071022-162224'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14306',
internalId:  '',
customField: '20071021-053901'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14301',
internalId:  '',
customField: '20071021-053901'
};
webappMappings['7008']=webappMappings['7008-635']={
webappId:    '7008',
documentId:  '1520',
internalId:  '635',
customField: 'language:en;country:US;'
};
var canonHostname = 'wscwrk02.ehost-services.com';
var accountId     = 'AEN010INVCV2';
var companyName   = 'Minjan+Brunau';
var htmlTitle	  = 'Minjan+Brunau+Zurich';
var metaKeywords  = '';
var metaContents  = '';
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();
};
