/* [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','1814',jdecode('Home'),jdecode(''),'/1814.html','true',[],'',''],
	['PAGE','607935',jdecode('News'),jdecode(''),'/607935.html','true',[],'',''],
	['PAGE','607956',jdecode('Band'),jdecode(''),'/607956/index.html','true',[ 
		['PAGE','607977',jdecode('%C2%B0Muckel'),jdecode(''),'/607956/607977.html','true',[],'',''],
		['PAGE','607998',jdecode('Joe'),jdecode(''),'/607956/607998.html','true',[],'',''],
		['PAGE','608019',jdecode('Lui'),jdecode(''),'/607956/608019.html','true',[],'',''],
		['PAGE','608040',jdecode('Lugge'),jdecode(''),'/607956/608040.html','true',[],'','']
	],'',''],
	['PAGE','608061',jdecode('Interviews'),jdecode(''),'/608061/index.html','true',[ 
		['PAGE','608082',jdecode('Band-Interview+am+04.07.09'),jdecode(''),'/608061/608082.html','true',[],'',''],
		['PAGE','620135',jdecode('Band-Interview+am+08.01.10'),jdecode(''),'/608061/620135.html','true',[],'',''],
		['PAGE','626335',jdecode('Band-Interview+am+30.01.10'),jdecode(''),'/608061/626335.html','true',[],'','']
	],'',''],
	['PAGE','608103',jdecode('Termine'),jdecode(''),'/608103.html','true',[],'',''],
	['PAGE','608124',jdecode('Konzertberichte'),jdecode(''),'/608124/index.html','true',[ 
		['PAGE','608145',jdecode('Konzert+am+04.07.09'),jdecode(''),'/608124/608145.html','true',[],'',''],
		['PAGE','608166',jdecode('Konzert+am+10.10.09'),jdecode(''),'/608124/608166.html','true',[],'',''],
		['PAGE','608187',jdecode('Konzert+am+10.12.09'),jdecode(''),'/608124/608187.html','true',[],'',''],
		['PAGE','618735',jdecode('Konzert+am+08.01.10'),jdecode(''),'/608124/618735.html','true',[],'',''],
		['PAGE','624935',jdecode('Konzert+am+30.01.10'),jdecode(''),'/608124/624935.html','true',[],'',''],
		['PAGE','630535',jdecode('Konzert+am+24.04.10'),jdecode(''),'/608124/630535.html','true',[],'','']
	],'',''],
	['PAGE','608208',jdecode('Fotos'),jdecode(''),'/608208/index.html','true',[ 
		['PAGE','608229',jdecode('Pressefotos'),jdecode(''),'/608208/608229.html','true',[],'',''],
		['PAGE','608250',jdecode('Eigene+Fotos'),jdecode(''),'/608208/608250.html','true',[],'','']
	],'',''],
	['PAGE','608271',jdecode('Aktionen'),jdecode(''),'/608271/index.html','true',[ 
		['PAGE','622235',jdecode('Colour+the+...'),jdecode(''),'/608271/622235.html','true',[],'','']
	],'',''],
	['PAGE','608292',jdecode('G%C3%A4stebuch'),jdecode(''),'/608292.html','true',[],'',''],
	['PAGE','608313',jdecode('Impressum'),jdecode(''),'/608313.html','true',[],'','']];
var siteelementCount=26;
theSitetree.topTemplateName='Push';
theSitetree.paletteFamily='B99BC7';
theSitetree.keyvisualId='11121';
theSitetree.keyvisualName='kv_11121.jpg';
theSitetree.fontsetId='32013';
theSitetree.graphicsetId='13840';
theSitetree.contentColor='2C4E8B';
theSitetree.contentBGColor='FFFFFF';
var localeDef={
  language: 'de',
  country: 'DE'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Push',
				paletteFamily: 	'B99BC7',
				keyvisualId: 	'11121',
				keyvisualName: 	'kv_11121.jpg',
				fontsetId: 		'32013',
				graphicsetId: 	'13840',
				contentColor: 	'2C4E8B',
				contentBGColor: 'FFFFFF',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'true',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1814',
internalId:  '',
customField: '20091228-155211'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '1814',
internalId:  '1006',
customField: '1006'
};
webappMappings['1501']=webappMappings['1501-585917']={
webappId:    '1501',
documentId:  '1814',
internalId:  '585917',
customField: '1501'
};
webappMappings['7002']=webappMappings['7002-2998']={
webappId:    '7002',
documentId:  '608292',
internalId:  '2998',
customField: 'language:de;country:DE;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '607956',
internalId:  '',
customField: '20091228-155241'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '607935',
internalId:  '',
customField: '20100528-191329'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '607977',
internalId:  '',
customField: '20100106-113928'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '607998',
internalId:  '',
customField: '20100110-113154'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608019',
internalId:  '',
customField: '20100103-160656'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608040',
internalId:  '',
customField: '20100112-131043'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608061',
internalId:  '',
customField: '20091228-142325'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608082',
internalId:  '',
customField: '20091228-155449'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608103',
internalId:  '',
customField: '20100407-180023'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608124',
internalId:  '',
customField: '20091228-144410'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608145',
internalId:  '',
customField: '20091228-155553'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608166',
internalId:  '',
customField: '20091228-155644'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608187',
internalId:  '',
customField: '20091228-155730'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608208',
internalId:  '',
customField: '20091228-151657'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608229',
internalId:  '',
customField: '20091228-151800'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608250',
internalId:  '',
customField: '20091228-151851'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608271',
internalId:  '',
customField: '20100117-120204'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608292',
internalId:  '',
customField: '20091229-185939'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '608313',
internalId:  '',
customField: '20100128-164725'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '618735',
internalId:  '',
customField: '20100111-135037'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '620135',
internalId:  '',
customField: '20100205-122452'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '624935',
internalId:  '',
customField: '20100203-140343'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '626335',
internalId:  '',
customField: '20100205-123421'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '622235',
internalId:  '',
customField: '20100120-173208'
};
webappMappings['7060']=webappMappings['7060-7b9e9bf97451938ac350357e2e04409e']={
webappId:    '7060',
documentId:  '622235',
internalId:  '7b9e9bf97451938ac350357e2e04409e',
customField: 'language:de;country:DE;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '630535',
internalId:  '',
customField: '20100430-155023'
};
webappMappings['7060']=webappMappings['7060-44a6ab80447005feaef81838cc800316']={
webappId:    '7060',
documentId:  '608229',
internalId:  '44a6ab80447005feaef81838cc800316',
customField: 'language:de;country:DE;'
};
webappMappings['7060']=webappMappings['7060-9e910d10992778462cdcc36927957c28']={
webappId:    '7060',
documentId:  '608250',
internalId:  '9e910d10992778462cdcc36927957c28',
customField: 'language:de;country:DE;'
};
var canonHostname = 'wsc.alfahosting.de';
var accountId     = 'AAHS10INX2D6';
var companyName   = 'Die+TOS-Supportpage';
var htmlTitle	  = 'Die+erste+TOS-Supportpage';
var metaKeywords  = '';
var metaContents  = 'Die+erste+Supportpage+der+Band+TOS.';
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();
};

