/* [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','652211',jdecode('Inhalt++-++Indice'),jdecode(''), jdecode('%2F652211.html'), 'true',[],'',''],
	['PAGE','1105757',jdecode('Oggi+nuovo+III'),jdecode(''), jdecode('%2F1105757%2Findex.html'), 'true',[ 
		['PAGE','949925',jdecode('Oggi+nuovo+II'),jdecode(''), jdecode('%2F1105757%2F949925.html'), 'true',[],'',''],
		['PAGE','4521',jdecode('Oggi+nuovo+I+'),jdecode(''), jdecode('%2F1105757%2F4521.html'), 'true',[],'','']
	],'',''],
	['PAGE','4578',jdecode('Chi+siamo+-+Wir+zu+uns'),jdecode(''), jdecode('%2F4578.html'), 'true',[],'',''],
	['PAGE','4686',jdecode('SEGELSCHULE+scuolavela'),jdecode(''), jdecode('%2F4686.html'), 'true',[],'',''],
	['PAGE','59254',jdecode('Sailport+Club+News++'),jdecode(''), jdecode('%2F59254.html'), 'true',[],'',''],
	['PAGE','1017446',jdecode('Brissavizi-Brissawitzi+2'),jdecode(''), jdecode('%2F1017446.html'), 'true',[],'',''],
	['PAGE','1029546',jdecode('Partnervelica+3++17.6.10'),jdecode(''), jdecode('%2F1029546.html'), 'true',[],'',''],
	['PAGE','981546',jdecode('Scrivania+3+'),jdecode(''), jdecode('%2F981546.html'), 'true',[],'',''],
	['PAGE','262900',jdecode('Partnervelica+2+1.9.07+'),jdecode(''), jdecode('%2F262900%2Findex.html'), 'true',[ 
		['PAGE','262000',jdecode('Partner+Velica+1'),jdecode(''), jdecode('%2F262900%2F262000.html'), 'true',[],'','']
	],'',''],
	['PAGE','1002046',jdecode('Vetrina+II+ab+1.5.2010'),jdecode(''), jdecode('%2F1002046.html'), 'true',[],'',''],
	['PAGE','1002246',jdecode('Vetrina-Schaufenster+I'),jdecode(''), jdecode('%2F1002246.html'), 'true',[],'',''],
	['PAGE','383200',jdecode('Brissavizi-Brissawitzi+1'),jdecode(''), jdecode('%2F383200.html'), 'true',[],'',''],
	['PAGE','304900',jdecode('Scrivania+2'),jdecode(''), jdecode('%2F304900%2Findex.html'), 'true',[ 
		['PAGE','27101',jdecode('Scrivania-Schreibhaus+1+'),jdecode(''), jdecode('%2F304900%2F27101.html'), 'true',[],'',''],
		['PAGE','204800',jdecode('brucia+pelo+Brennpunkt'),jdecode(''), jdecode('%2F304900%2F204800.html'), 'true',[],'','']
	],'',''],
	['PAGE','33262',jdecode('Archiv'),jdecode(''), jdecode('%2F33262%2Findex.html'), 'true',[ 
		['PAGE','44565',jdecode('Vortrag+zur+Nautik'),jdecode(''), jdecode('%2F33262%2F44565.html'), 'true',[],'',''],
		['PAGE','508011',jdecode('Brissabacco+%26+Schiavit%C3%B9'),jdecode(''), jdecode('%2F33262%2F508011.html'), 'true',[],'',''],
		['PAGE','679011',jdecode('Interpellanze+'),jdecode(''), jdecode('%2F33262%2F679011.html'), 'true',[],'','']
	],'',''],
	['PAGE','187621',jdecode('Flash+%2F+Flaschenhals'),jdecode(''), jdecode('%2F187621.html'), 'true',[],'',''],
	['PAGE','30302',jdecode('Campagna+elettorale'),jdecode(''), jdecode('%2F30302.html'), 'false',[],'',''],
	['PAGE','1182661',jdecode('Campagna+elettorale'),jdecode(''), jdecode('%2F1182661.html'), 'true',[],'','']];
var siteelementCount=25;
theSitetree.topTemplateName='Architekt';
theSitetree.paletteFamily='8CBBD8';
theSitetree.keyvisualId='1685';
theSitetree.keyvisualName='abendstimmung.jpg';
theSitetree.fontsetId='280';
theSitetree.graphicsetId='348';
theSitetree.contentColor='000066';
theSitetree.contentBGColor='8CBBD8';
var localeDef={
  language: 'de',
  country: 'CH'
};
var prodDef={
  wl_name: 'bluewin',
  product: 'WSCBLUSSSLYTC2MH'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Architekt',
				paletteFamily: 	'8CBBD8',
				keyvisualId: 	'1685',
				keyvisualName: 	'abendstimmung.jpg',
				fontsetId: 		'280',
				graphicsetId: 	'348',
				contentColor: 	'000066',
				contentBGColor: '8CBBD8',
				a_color: 		'8CBBD8',
				b_color: 		'338299',
				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:  '4686',
internalId:  '',
customField: '20120106-164421'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '59254',
internalId:  '',
customField: '20120105-220820'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1002046',
internalId:  '',
customField: '20111230-163057'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '1105757',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '652211',
internalId:  '',
customField: '20120220-225142'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4521',
internalId:  '',
customField: '20100427-184412'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4578',
internalId:  '',
customField: '20101015-105511'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '262900',
internalId:  '',
customField: '20110218-230112'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '262000',
internalId:  '',
customField: '20071004-041947'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '508011',
internalId:  '',
customField: '20080803-193908'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '383200',
internalId:  '',
customField: '20120208-130029'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '679011',
internalId:  '',
customField: '20100627-183753'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '304900',
internalId:  '',
customField: '20110115-002856'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27101',
internalId:  '',
customField: '20080317-103740'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '204800',
internalId:  '',
customField: '20091210-183241'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33262',
internalId:  '',
customField: '20100627-185256'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '44565',
internalId:  '',
customField: '20061011-025906'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '187621',
internalId:  '',
customField: '20100413-202902'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '30302',
internalId:  '',
customField: '20061011-025906'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1182661',
internalId:  '',
customField: '20110331-000939'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '949925',
internalId:  '',
customField: '20101223-164622'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '981546',
internalId:  '',
customField: '20120205-125118'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1029546',
internalId:  '',
customField: '20120213-021902'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1105757',
internalId:  '',
customField: '20120220-224154'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1002246',
internalId:  '',
customField: '20100526-174316'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1017446',
internalId:  '',
customField: '20120212-193549'
};
var webAppHostname = 'cgi.hpt001.bluewin.ch:80';
var canonHostname = 'hptworkerdb01b.bluewin.ch';
var accountId     = 'ABW0X0INXXGO';
var companyName   = 'Segelschule+Scuolavela+Brissago';
var htmlTitle	  = 'Sail+port+Brissago+-+Segelschule+Brissago';
var metaKeywords  = 'Segeln++Brissago';
var metaContents  = 'Segeln';
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();
};

