/* [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','5126',jdecode('Home'),jdecode(''), jdecode('%2F5126.html'), 'true',[],'',''],
	['PAGE','7001',jdecode('Modegesch%C3%A4ft'),jdecode(''), jdecode('%2F7001.html'), 'true',[],'',''],
	['PAGE','7022',jdecode('Personal'),jdecode(''), jdecode('%2F7022.html'), 'true',[],'',''],
	['PAGE','7622',jdecode('%C3%96ffnungszeiten'),jdecode(''), jdecode('%2F7622.html'), 'true',[],'',''],
	['PAGE','9801',jdecode('Jobs'),jdecode(''), jdecode('%2F9801.html'), 'true',[],'',''],
	['PAGE','7601',jdecode('Produkte'),jdecode(''), jdecode('%2F7601.html'), 'true',[],'',''],
	['PAGE','16301',jdecode('Medien'),jdecode(''), jdecode('%2F16301%2Findex.html'), 'true',[ 
		['PAGE','19401',jdecode('2009'),jdecode(''), jdecode('%2F16301%2F19401.html'), 'false',[],'',''],
		['PAGE','25001',jdecode('Modeschau+Fr%C3%BChling'),jdecode(''), jdecode('%2F16301%2F25001.html'), 'false',[],'',''],
		['PAGE','19422',jdecode('2010'),jdecode(''), jdecode('%2F16301%2F19422.html'), 'true',[],'',''],
		['PAGE','25022',jdecode('Modeschau+Fr%C3%BChling'),jdecode(''), jdecode('%2F16301%2F25022.html'), 'false',[],'',''],
		['PAGE','25043',jdecode('Modeschau+Herbst'),jdecode(''), jdecode('%2F16301%2F25043.html'), 'false',[],'',''],
		['PAGE','25064',jdecode('Modeschau+Altersheim+Wangen'),jdecode(''), jdecode('%2F16301%2F25064.html'), 'false',[],'',''],
		['PAGE','19443',jdecode('2011'),jdecode(''), jdecode('%2F16301%2F19443.html'), 'false',[],'',''],
		['PAGE','25085',jdecode('Modeschau+Fr%C3%BChling'),jdecode(''), jdecode('%2F16301%2F25085.html'), 'false',[],'','']
	],'',''],
	['PAGE','29701',jdecode('Newsletter'),jdecode(''), jdecode('%2F29701.html'), 'true',[],'',''],
	['PAGE','8401',jdecode('Kontakt'),jdecode(''), jdecode('%2F8401%2Findex.html'), 'true',[ 
		['PAGE','16322',jdecode('Lageplan'),jdecode(''), jdecode('%2F8401%2F16322.html'), 'true',[],'','']
	],'','']];
var siteelementCount=18;
theSitetree.topTemplateName='Triangle';
theSitetree.paletteFamily='004165';
theSitetree.keyvisualId='12018';
theSitetree.keyvisualName='kv_12018.jpg';
theSitetree.fontsetId='33260';
theSitetree.graphicsetId='14140';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='004165';
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: 			'Triangle',
				paletteFamily: 	'004165',
				keyvisualId: 	'12018',
				keyvisualName: 	'kv_12018.jpg',
				fontsetId: 		'33260',
				graphicsetId: 	'14140',
				contentColor: 	'FFFFFF',
				contentBGColor: '004165',
				a_color: 		'004165',
				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:  '5126',
internalId:  '',
customField: '20120208-181942'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19401',
internalId:  '',
customField: '20110815-181802'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7601',
internalId:  '',
customField: '20110806-145345'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7622',
internalId:  '',
customField: '20111219-155006'
};
webappMappings['7060']=webappMappings['7060-d1e0455aaade9ba613175a4cc43daa85']={
webappId:    '7060',
documentId:  '25001',
internalId:  'd1e0455aaade9ba613175a4cc43daa85',
customField: 'language:de;country:CH;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7001',
internalId:  '',
customField: '20111202-235215'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7022',
internalId:  '',
customField: '20111202-214933'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8401',
internalId:  '',
customField: '20110925-133321'
};
webappMappings['4001']=webappMappings['4001-33025878']={
webappId:    '4001',
documentId:  '7601',
internalId:  '33025878',
customField: 'language:de;country:CH;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9801',
internalId:  '',
customField: '20111202-214139'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19443',
internalId:  '',
customField: '20110815-182019'
};
webappMappings['2001']=webappMappings['2001-location']={
webappId:    '2001',
documentId:  '16322',
internalId:  'location',
customField: 'language:de;country:CH;isIncluded:true;'
};
webappMappings['7008']=webappMappings['7008-12572']={
webappId:    '7008',
documentId:  '8401',
internalId:  '12572',
customField: 'language:de;country:CH;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19422',
internalId:  '',
customField: '20111202-214306'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '16301',
internalId:  '',
customField: '20111202-213723'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '16322',
internalId:  '',
customField: '20110709-114058'
};
webappMappings['7060']=webappMappings['7060-621c53c9e2792be0a6970477142665d4']={
webappId:    '7060',
documentId:  '25022',
internalId:  '621c53c9e2792be0a6970477142665d4',
customField: 'language:de;country:CH;'
};
webappMappings['7060']=webappMappings['7060-ee80c9fe64e0ab5a2c5ba6496f6d27c3']={
webappId:    '7060',
documentId:  '25043',
internalId:  'ee80c9fe64e0ab5a2c5ba6496f6d27c3',
customField: 'language:de;country:CH;'
};
webappMappings['7060']=webappMappings['7060-20a39ca8d1d408a18876630a509ed36d']={
webappId:    '7060',
documentId:  '25064',
internalId:  '20a39ca8d1d408a18876630a509ed36d',
customField: 'language:de;country:CH;'
};
webappMappings['7060']=webappMappings['7060-988f87ab45c7f7c8f1cf5579beab9435']={
webappId:    '7060',
documentId:  '25085',
internalId:  '988f87ab45c7f7c8f1cf5579beab9435',
customField: 'language:de;country:CH;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25001',
internalId:  '',
customField: '20110814-103250'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25022',
internalId:  '',
customField: '20111202-213243'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25043',
internalId:  '',
customField: '20110814-103255'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25064',
internalId:  '',
customField: '20111202-213303'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25085',
internalId:  '',
customField: '20110814-103258'
};
webappMappings['7008']=webappMappings['7008-13072']={
webappId:    '7008',
documentId:  '29701',
internalId:  '13072',
customField: 'language:de;country:CH;'
};
webappMappings['5000']=webappMappings['5000--']={
webappId:    '5000',
documentId:  '29701',
internalId:  '-',
customField: '20111105-112331'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '5126',
internalId:  '1006',
customField: '1006'
};
var webAppHostname = 'cgi.hpt001.bluewin.ch:80';
var canonHostname = 'hptworkerdb01b.bluewin.ch';
var accountId     = 'ABW330INE6X4';
var companyName   = 'GESCHWISTER+WINET';
var htmlTitle	  = 'Geschwister+Winet';
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();
};

