/* [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','8923',jdecode('Home'),jdecode(''), jdecode('%2F8923.html'), 'true',[],'',''],
	['PAGE','244212',jdecode('Mariages+2012'),jdecode(''), jdecode('%2F244212.html'), 'true',[],'',''],
	['PAGE','218212',jdecode('Mariages+2011'),jdecode(''), jdecode('%2F218212%2Findex.html'), 'true',[ 
		['PAGE','242112',jdecode('Elodie+et+Adriano'),jdecode(''), jdecode('%2F218212%2F242112.html'), 'true',[],'',''],
		['PAGE','239112',jdecode('Aur%C3%A9lie+et+Reynald'),jdecode(''), jdecode('%2F218212%2F239112.html'), 'true',[],'',''],
		['PAGE','239133',jdecode('Marcia+et+Philippe'),jdecode(''), jdecode('%2F218212%2F239133.html'), 'true',[],'',''],
		['PAGE','238312',jdecode('Nathalie+%26+Artie'),jdecode(''), jdecode('%2F218212%2F238312.html'), 'true',[],'',''],
		['PAGE','236912',jdecode('Jenna+et+Sergio'),jdecode(''), jdecode('%2F218212%2F236912.html'), 'true',[],'',''],
		['PAGE','236933',jdecode('Carole+et+Patrice'),jdecode(''), jdecode('%2F218212%2F236933.html'), 'true',[],'',''],
		['PAGE','236212',jdecode('Louisa+et+Mathias'),jdecode(''), jdecode('%2F218212%2F236212.html'), 'true',[],'',''],
		['PAGE','234312',jdecode('Camilla+et+Nadir'),jdecode(''), jdecode('%2F218212%2F234312.html'), 'true',[],'',''],
		['PAGE','234333',jdecode('Nathalie+et+Fabien'),jdecode(''), jdecode('%2F218212%2F234333.html'), 'true',[],'',''],
		['PAGE','232812',jdecode('Solange+et+Fred'),jdecode(''), jdecode('%2F218212%2F232812.html'), 'true',[],'',''],
		['PAGE','231212',jdecode('Magali+et+Laurent'),jdecode(''), jdecode('%2F218212%2F231212.html'), 'true',[],'',''],
		['PAGE','231233',jdecode('Murielle+et+Gr%C3%A9goire'),jdecode(''), jdecode('%2F218212%2F231233.html'), 'true',[],'',''],
		['PAGE','241012',jdecode('Sonia+et+S%C3%A9bastien'),jdecode(''), jdecode('%2F218212%2F241012.html'), 'true',[],'',''],
		['PAGE','231254',jdecode('Emilie+et+Julien'),jdecode(''), jdecode('%2F218212%2F231254.html'), 'true',[],'',''],
		['PAGE','230412',jdecode('Marjorie+%26+Ga%C3%ABl'),jdecode(''), jdecode('%2F218212%2F230412.html'), 'true',[],'',''],
		['PAGE','220612',jdecode('Corinne%26J%C3%A9r%C3%B4me'),jdecode(''), jdecode('%2F218212%2F220612.html'), 'true',[],'',''],
		['PAGE','218233',jdecode('Natacha+%26+Emmanuel'),jdecode(''), jdecode('%2F218212%2F218233.html'), 'true',[],'','']
	],'',''],
	['PAGE','185112',jdecode('Mariages+2010'),jdecode(''), jdecode('%2F185112%2Findex.html'), 'true',[ 
		['PAGE','205512',jdecode('Annouk+et+Fr%C3%A9d'),jdecode(''), jdecode('%2F185112%2F205512.html'), 'true',[],'',''],
		['PAGE','206412',jdecode('Sonia+et+Bruno'),jdecode(''), jdecode('%2F185112%2F206412.html'), 'true',[],'',''],
		['PAGE','203712',jdecode('Florence%26S%C3%A9bastien'),jdecode(''), jdecode('%2F185112%2F203712.html'), 'true',[],'',''],
		['PAGE','202712',jdecode('Murielle+et+Andr%C3%A9'),jdecode(''), jdecode('%2F185112%2F202712.html'), 'true',[],'',''],
		['PAGE','201712',jdecode('Ga%C3%ABlle+et+Damien'),jdecode(''), jdecode('%2F185112%2F201712.html'), 'true',[],'',''],
		['PAGE','200812',jdecode('Tanya+et+Kim'),jdecode(''), jdecode('%2F185112%2F200812.html'), 'true',[],'',''],
		['PAGE','195812',jdecode('No%C3%A9mie+et+Helder'),jdecode(''), jdecode('%2F185112%2F195812.html'), 'true',[],'',''],
		['PAGE','197912',jdecode('Caroline+et+Dariush'),jdecode(''), jdecode('%2F185112%2F197912.html'), 'true',[],'',''],
		['PAGE','199112',jdecode('Anne-Claire+et+Xavier'),jdecode(''), jdecode('%2F185112%2F199112.html'), 'true',[],'',''],
		['PAGE','196212',jdecode('Sabrina+et+Dany'),jdecode(''), jdecode('%2F185112%2F196212.html'), 'true',[],'',''],
		['PAGE','196512',jdecode('Laura+et+Alain'),jdecode(''), jdecode('%2F185112%2F196512.html'), 'true',[],'',''],
		['PAGE','188312',jdecode('Nadine+et+Lionel'),jdecode(''), jdecode('%2F185112%2F188312.html'), 'true',[],'',''],
		['PAGE','188333',jdecode('Sylvie+et+Fabien'),jdecode(''), jdecode('%2F185112%2F188333.html'), 'true',[],'',''],
		['PAGE','187512',jdecode('Florence+et+Beno%C3%AEt'),jdecode(''), jdecode('%2F185112%2F187512.html'), 'true',[],'',''],
		['PAGE','186312',jdecode('Catia+et+Yann'),jdecode(''), jdecode('%2F185112%2F186312.html'), 'true',[],'',''],
		['PAGE','185133',jdecode('Monica+%26+J%C3%A9r%C3%B4me'),jdecode(''), jdecode('%2F185112%2F185133.html'), 'true',[],'','']
	],'',''],
	['PAGE','230112',jdecode('Fian%C3%A7ailles%2FCouples'),jdecode(''), jdecode('%2F230112%2Findex.html'), 'true',[ 
		['PAGE','243012',jdecode('Val+et+Flo'),jdecode(''), jdecode('%2F230112%2F243012.html'), 'true',[],'','']
	],'',''],
	['PAGE','184212',jdecode('Future+parents'),jdecode(''), jdecode('%2F184212.html'), 'true',[],'',''],
	['PAGE','244112',jdecode('Famille'),jdecode(''), jdecode('%2F244112.html'), 'true',[],'',''],
	['PAGE','244133',jdecode('B%C3%A9b%C3%A9+%2F+Enfants'),jdecode(''), jdecode('%2F244133.html'), 'true',[],'',''],
	['PAGE','244512',jdecode('Galerie'),jdecode(''), jdecode('%2F244512.html'), 'true',[],'',''],
	['PAGE','157701',jdecode('Photobooks'),jdecode(''), jdecode('%2F157701.html'), 'true',[],'',''],
	['PAGE','181012',jdecode('Contact+%2F+offre'),jdecode(''), jdecode('%2F181012.html'), 'true',[],'',''],
	['PAGE','158701',jdecode('Livre+d%26%23x27%3Bor'),jdecode(''), jdecode('%2F158701.html'), 'true',[],'',''],
	['PAGE','9201',jdecode('Forfaits+%2F+Tarifs'),jdecode(''), jdecode('%2F9201.html'), 'true',[],'',''],
	['PAGE','49965',jdecode('Remerciements'),jdecode(''), jdecode('%2F49965.html'), 'true',[],'',''],
	['PAGE','28332',jdecode('Partenaires+et+liens'),jdecode(''), jdecode('%2F28332.html'), 'true',[],'','']];
var siteelementCount=49;
theSitetree.topTemplateName='Vienna';
theSitetree.paletteFamily='D6D2C5';
theSitetree.keyvisualId='11894';
theSitetree.keyvisualName='kv_11894.jpg';
theSitetree.fontsetId='33183';
theSitetree.graphicsetId='14088';
theSitetree.contentColor='696146';
theSitetree.contentBGColor='ebe8df';
var localeDef={
  language: 'fr',
  country: 'FR'
};
var prodDef={
  wl_name: 'bluewin',
  product: 'WSCBLUSSSLYTC2MX'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Vienna',
				paletteFamily: 	'D6D2C5',
				keyvisualId: 	'11894',
				keyvisualName: 	'kv_11894.jpg',
				fontsetId: 		'33183',
				graphicsetId: 	'14088',
				contentColor: 	'696146',
				contentBGColor: 'ebe8df',
				a_color: 		'EBE8DF',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'false',
				contentFontFace:'Tahoma',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '8923',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '157701',
internalId:  '',
customField: '20120206-221033'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8923',
internalId:  '',
customField: '20120206-215416'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9201',
internalId:  '',
customField: '20120130-222825'
};
webappMappings['7008']=webappMappings['7008-7572']={
webappId:    '7008',
documentId:  '181012',
internalId:  '7572',
customField: 'language:fr;country:FR;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '49965',
internalId:  '',
customField: '20081123-213321'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28332',
internalId:  '',
customField: '20120131-231518'
};
webappMappings['1002']=webappMappings['1002-158701abw0x0inxspv']={
webappId:    '1002',
documentId:  '158701',
internalId:  '158701abw0x0inxspv',
customField: 'icq=false'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '158701',
internalId:  '',
customField: '20090713-224011'
};
webappMappings['1501']=webappMappings['1501-389456']={
webappId:    '1501',
documentId:  '8923',
internalId:  '389456',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '195812',
internalId:  '',
customField: '20101010-203931'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '196512',
internalId:  '',
customField: '20100808-172238'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '181012',
internalId:  '',
customField: '20120131-231344'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '184212',
internalId:  '',
customField: '20120206-220450'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '185112',
internalId:  '',
customField: '20101022-234127'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '185133',
internalId:  '',
customField: '20101010-204406'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '186312',
internalId:  '',
customField: '20101010-204320'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '187512',
internalId:  '',
customField: '20101010-204254'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '188333',
internalId:  '',
customField: '20101010-204217'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '188312',
internalId:  '',
customField: '20101010-204138'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '196212',
internalId:  '',
customField: '20100808-172154'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '197912',
internalId:  '',
customField: '20100808-154516'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '199112',
internalId:  '',
customField: '20101010-204027'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '200812',
internalId:  '',
customField: '20101010-203856'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '201712',
internalId:  '',
customField: '20100906-212550'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '202712',
internalId:  '',
customField: '20101010-203806'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '203712',
internalId:  '',
customField: '20101010-203716'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '205512',
internalId:  '',
customField: '20101017-212236'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '206412',
internalId:  '',
customField: '20101022-234448'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '218212',
internalId:  '',
customField: '20111012-223143'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '218233',
internalId:  '',
customField: '20110125-061113'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '220612',
internalId:  '',
customField: '20110526-223639'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '230112',
internalId:  '',
customField: '20120206-220120'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '230412',
internalId:  '',
customField: '20110621-214830'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '231254',
internalId:  '',
customField: '20110627-224750'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '231233',
internalId:  '',
customField: '20110627-223616'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '231212',
internalId:  '',
customField: '20110714-222024'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '232812',
internalId:  '',
customField: '20110718-221038'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '234333',
internalId:  '',
customField: '20110821-225818'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '234312',
internalId:  '',
customField: '20110723-185823'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '236212',
internalId:  '',
customField: '20110905-174507'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '236933',
internalId:  '',
customField: '20111002-151338'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '236912',
internalId:  '',
customField: '20110912-230754'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '238312',
internalId:  '',
customField: '20111009-215419'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '239133',
internalId:  '',
customField: '20111005-231131'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '239112',
internalId:  '',
customField: '20111005-231059'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '241012',
internalId:  '',
customField: '20111016-123019'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '242112',
internalId:  '',
customField: '20111012-223732'
};
webappMappings['5000']=webappMappings['5000--']={
webappId:    '5000',
documentId:  '243012',
internalId:  '-',
customField: '20120206-220219'
};
webappMappings['5000']=webappMappings['5000--']={
webappId:    '5000',
documentId:  '244112',
internalId:  '-',
customField: '20120206-220631'
};
webappMappings['5000']=webappMappings['5000--']={
webappId:    '5000',
documentId:  '244133',
internalId:  '-',
customField: '20120206-220748'
};
webappMappings['5000']=webappMappings['5000--']={
webappId:    '5000',
documentId:  '244512',
internalId:  '-',
customField: '20120206-220828'
};
webappMappings['5000']=webappMappings['5000--']={
webappId:    '5000',
documentId:  '244212',
internalId:  '-',
customField: '20120105-142630'
};
var webAppHostname = 'cgi.hpt001.bluewin.ch:80';
var canonHostname = 'hptworkerdb01b.bluewin.ch';
var accountId     = 'ABW0X0INXSPV';
var companyName   = 'www.amarsi.ch+++++++++++++++++++++++++++++++++++++++Photographie';
var htmlTitle	  = 'Photos+de+mariage+Amarsi';
var metaKeywords  = 'Photos++de+mariage%2CMariage%2CPhotos%2CReportage%2CPhotos+de+c%C3%A9r%C3%A9monie%2CPhotographe%2CFelix+Oberhaensli%2CPhotographie%2CPhoto+de+mariage%2CAmarsi%2Cfetes+de+famille%2CVaud%2CLausanne%2Cmariages%2Cphotographie+de+mariage';
var metaContents  = 'Photos+de+mariage%2CMariage%2Creportage+photo%2C+photographe%2Cphotographie+de+mariage%2Cmariages%2C+vaud+';
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();
};

