/* [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','4801',jdecode('Home'),jdecode(''), jdecode('%2F4801.html'), 'true',[],'',''],
	['PAGE','4852',jdecode('About+us'),jdecode(''), jdecode('%2F4852%2Findex.html'), 'true',[ 
		['PAGE','4915',jdecode('Committee+INC'),jdecode(''), jdecode('%2F4852%2F4915.html'), 'true',[],'',''],
		['PAGE','11601',jdecode('Membership'),jdecode(''), jdecode('%2F4852%2F11601.html'), 'true',[],'',''],
		['PAGE','14201',jdecode('History'),jdecode(''), jdecode('%2F4852%2F14201.html'), 'true',[],'',''],
		['PAGE','48412',jdecode('Constitution'),jdecode(''), jdecode('%2F4852%2F48412.html'), 'true',[],'','']
	],'',''],
	['PAGE','4894',jdecode('What+we+do'),jdecode(''), jdecode('%2F4894%2Findex.html'), 'true',[ 
		['PAGE','14222',jdecode('Congresses'),jdecode(''), jdecode('%2F4894%2F14222.html'), 'true',[],'',''],
		['PAGE','14243',jdecode('Publications'),jdecode(''), jdecode('%2F4894%2F14243.html'), 'true',[],'',''],
		['PAGE','14264',jdecode('Patronage'),jdecode(''), jdecode('%2F4894%2F14264.html'), 'true',[],'',''],
		['PAGE','14285',jdecode('INC+Grants'),jdecode(''), jdecode('%2F4894%2F14285.html'), 'true',[],'','']
	],'',''],
	['PAGE','44812',jdecode('Taormina+2015'),jdecode(''), jdecode('%2F44812%2Findex.html'), 'true',[ 
		['PAGE','64312',jdecode('The+logo+of+2015'),jdecode(''), jdecode('%2F44812%2F64312.html'), 'true',[],'','']
	],'',''],
	['PAGE','6101',jdecode('Glasgow+2009'),jdecode(''), jdecode('%2F6101%2Findex.html'), 'true',[ 
		['PAGE','43612',jdecode('Data+protection'),jdecode(''), jdecode('%2F6101%2F43612.html'), 'true',[],'','']
	],'',''],
	['PAGE','22801',jdecode('Articles'),jdecode(''), jdecode('%2F22801%2Findex.html'), 'true',[ 
		['PAGE','6122',jdecode('Numismatists'),jdecode(''), jdecode('%2F22801%2F6122.html'), 'true',[],'',''],
		['PAGE','4936',jdecode('Collections'),jdecode(''), jdecode('%2F22801%2F4936.html'), 'true',[],'',''],
		['PAGE','31012',jdecode('Collectors'),jdecode(''), jdecode('%2F22801%2F31012.html'), 'true',[],'',''],
		['PAGE','22501',jdecode('Laws'),jdecode(''), jdecode('%2F22801%2F22501.html'), 'true',[],'',''],
		['PAGE','23501',jdecode('Obituaries'),jdecode(''), jdecode('%2F22801%2F23501.html'), 'true',[],'','']
	],'',''],
	['PAGE','21001',jdecode('Documents'),jdecode(''), jdecode('%2F21001%2Findex.html'), 'true',[ 
		['PAGE','21322',jdecode('e-Newsletter'),jdecode(''), jdecode('%2F21001%2F21322.html'), 'true',[],'',''],
		['PAGE','25601',jdecode('Congresses'),jdecode(''), jdecode('%2F21001%2F25601.html'), 'true',[],'',''],
		['PAGE','95912',jdecode('Survey+2002-2007'),jdecode(''), jdecode('%2F21001%2F95912.html'), 'true',[],'',''],
		['PAGE','40612',jdecode('e-Papers'),jdecode(''), jdecode('%2F21001%2F40612.html'), 'true',[],'','']
	],'',''],
	['PAGE','32412',jdecode('Travel+Grants'),jdecode(''), jdecode('%2F32412%2Findex.html'), 'true',[ 
		['PAGE','32433',jdecode('Grants+2012-13'),jdecode(''), jdecode('%2F32412%2F32433.html'), 'true',[],'',''],
		['PAGE','32454',jdecode('Bourses+2012-13'),jdecode(''), jdecode('%2F32412%2F32454.html'), 'true',[],'',''],
		['PAGE','32475',jdecode('Stipendien+2012-13'),jdecode(''), jdecode('%2F32412%2F32475.html'), 'true',[],'',''],
		['PAGE','47312',jdecode('Reports'),jdecode(''), jdecode('%2F32412%2F47312.html'), 'true',[],'','']
	],'',''],
	['PAGE','28001',jdecode('Coin+Cabinets'),jdecode(''), jdecode('%2F28001.html'), 'true',[],'',''],
	['PAGE','67512',jdecode('Exhibitions+2011'),jdecode(''), jdecode('%2F67512%2Findex.html'), 'true',[ 
		['PAGE','67533',jdecode('Austria%2C+Germany'),jdecode(''), jdecode('%2F67512%2F67533.html'), 'true',[],'',''],
		['PAGE','97612',jdecode('Switzerland%2C+France'),jdecode(''), jdecode('%2F67512%2F97612.html'), 'true',[],'','']
	],'',''],
	['PAGE','61112',jdecode('Online+Catalogues'),jdecode(''), jdecode('%2F61112.html'), 'true',[],'',''],
	['PAGE','97312',jdecode('Job+Offer'),jdecode(''), jdecode('%2F97312%2Findex.html'), 'true',[ 
		['PAGE','97333',jdecode('Austria%2C+Germany'),jdecode(''), jdecode('%2F97312%2F97333.html'), 'true',[],'',''],
		['PAGE','97412',jdecode('Switzerland%2C+France'),jdecode(''), jdecode('%2F97312%2F97412.html'), 'true',[],'','']
	],'',''],
	['PAGE','5041',jdecode('Contact'),jdecode(''), jdecode('%2F5041.html'), 'true',[],'',''],
	['PAGE','58012',jdecode('Links'),jdecode(''), jdecode('%2F58012.html'), 'true',[],'','']];
var siteelementCount=41;
theSitetree.topTemplateName='Popart';
theSitetree.paletteFamily='B9797B';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10731';
theSitetree.graphicsetId='10453';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FFFFFF';
var localeDef={
  language: 'de',
  country: 'CH'
};
var prodDef={
  wl_name: 'hostpoint',
  product: 'WSCSYSSSSLYTC21F'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Popart',
				paletteFamily: 	'B9797B',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10731',
				graphicsetId: 	'10453',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['1501']=webappMappings['1501-8732031']={
webappId:    '1501',
documentId:  '4801',
internalId:  '8732031',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4801',
internalId:  '',
customField: '20110510-124755'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '44812',
internalId:  '',
customField: '20110408-215740'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4852',
internalId:  '',
customField: '20100405-193046'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4915',
internalId:  '',
customField: '20120116-073921'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4894',
internalId:  '',
customField: '20120116-070747'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '32412',
internalId:  '',
customField: '20110403-110913'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43612',
internalId:  '',
customField: '20090928-110259'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '11601',
internalId:  '',
customField: '20100407-163817'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14201',
internalId:  '',
customField: '20090928-150605'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14222',
internalId:  '',
customField: '20110408-210250'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14243',
internalId:  '',
customField: '20120116-071559'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14264',
internalId:  '',
customField: '20100406-192959'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14285',
internalId:  '',
customField: '20120116-071811'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6101',
internalId:  '',
customField: '20110403-130407'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22801',
internalId:  '',
customField: '20110517-082023'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6122',
internalId:  '',
customField: '20110517-084209'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4936',
internalId:  '',
customField: '20110517-084351'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31012',
internalId:  '',
customField: '20110517-084248'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22501',
internalId:  '',
customField: '20111122-150940'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23501',
internalId:  '',
customField: '20110517-084033'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '21001',
internalId:  '',
customField: '20120116-073649'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '21322',
internalId:  '',
customField: '20120117-071517'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25601',
internalId:  '',
customField: '20120116-074702'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '97312',
internalId:  '',
customField: '20120130-123509'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '40612',
internalId:  '',
customField: '20100310-153955'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '32433',
internalId:  '',
customField: '20110403-125011'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '32454',
internalId:  '',
customField: '20110403-124931'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '32475',
internalId:  '',
customField: '20110403-124806'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28001',
internalId:  '',
customField: '20111016-171712'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5041',
internalId:  '',
customField: '20100310-151652'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '47312',
internalId:  '',
customField: '20090928-130615'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '48412',
internalId:  '',
customField: '20090928-145859'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '58012',
internalId:  '',
customField: '20110220-201133'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '61112',
internalId:  '',
customField: '20110405-203025'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '64312',
internalId:  '',
customField: '20110219-194740'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '67512',
internalId:  '',
customField: '20111213-124719'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '67533',
internalId:  '',
customField: '20110302-203351'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '95912',
internalId:  '',
customField: '20120116-073347'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '97612',
internalId:  '',
customField: '20120130-123744'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '97333',
internalId:  '',
customField: '20120130-122808'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '97412',
internalId:  '',
customField: '20120130-123208'
};
var webAppHostname = 'cgi.webomat.ch:80';
var canonHostname = 'webomat01.hostpoint.ch';
var accountId     = 'Ahp010INXVEO';
var companyName   = 'International+Numismatic+Council+INC+-+Conseil+international+de+numismatique+CIN';
var htmlTitle	  = 'INC+-+International+Numismatic+Council+%2F+CIN+-+Conseil+internationale+de+numismatique';
var metaKeywords  = 'numismatics+academic+societies';
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();
};

