/* [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','1601',jdecode('Home'),jdecode(''),'/1601.html','true',[],'',''],
	['PAGE','5701',jdecode('Contact+Us'),jdecode(''),'/5701.html','true',[],'',''],
	['PAGE','5143',jdecode('Downloads'),jdecode(''),'/5143.html','true',[],'',''],
	['PAGE','5101',jdecode('Links'),jdecode(''),'/5101.html','true',[],'',''],
	['PAGE','6901',jdecode('Administration'),jdecode(''),'/6901/index.html','true',[ 
		['PAGE','6922',jdecode('Acquisitioning'),jdecode(''),'/6901/6922.html','true',[],'',''],
		['PAGE','6943',jdecode('Allocation'),jdecode(''),'/6901/6943.html','true',[],'',''],
		['PAGE','6964',jdecode('Assessment'),jdecode(''),'/6901/6964.html','true',[],'',''],
		['PAGE','6985',jdecode('Budget'),jdecode(''),'/6901/6985.html','true',[],'',''],
		['PAGE','7006',jdecode('Planning'),jdecode(''),'/6901/7006.html','true',[],'',''],
		['PAGE','7027',jdecode('Resources'),jdecode(''),'/6901/7027.html','true',[],'','']
	],'',''],
	['PAGE','7048',jdecode('Maintenance'),jdecode(''),'/7048/index.html','true',[ 
		['PAGE','7069',jdecode('Activate'),jdecode(''),'/7048/7069.html','true',[],'',''],
		['PAGE','7090',jdecode('Breakdown'),jdecode(''),'/7048/7090.html','true',[],'',''],
		['PAGE','7111',jdecode('Commissioning'),jdecode(''),'/7048/7111.html','true',[],'',''],
		['PAGE','7132',jdecode('Execute'),jdecode(''),'/7048/7132.html','true',[],'',''],
		['PAGE','7153',jdecode('Measures'),jdecode(''),'/7048/7153.html','true',[],'',''],
		['PAGE','7174',jdecode('Recording'),jdecode(''),'/7048/7174.html','true',[],'',''],
		['PAGE','7195',jdecode('Replacement'),jdecode(''),'/7048/7195.html','true',[],'',''],
		['PAGE','6701',jdecode('Verify'),jdecode(''),'/7048/6701.html','true',[],'','']
	],'',''],
	['PAGE','7216',jdecode('Management'),jdecode(''),'/7216/index.html','true',[ 
		['PAGE','6601',jdecode('Classification'),jdecode(''),'/7216/6601.html','true',[],'',''],
		['PAGE','7237',jdecode('Configuration'),jdecode(''),'/7216/7237.html','true',[],'',''],
		['PAGE','6401',jdecode('i-Method'),jdecode(''),'/7216/6401.html','true',[],'',''],
		['PAGE','7258',jdecode('Organizational'),jdecode(''),'/7216/7258.html','true',[],'',''],
		['PAGE','7279',jdecode('Model'),jdecode(''),'/7216/7279.html','true',[],'',''],
		['PAGE','7300',jdecode('Software+Solution'),jdecode(''),'/7216/7300.html','true',[],'',''],
		['PAGE','7321',jdecode('Strategies'),jdecode(''),'/7216/7321.html','true',[],'','']
	],'',''],
	['PAGE','7342',jdecode('Plans'),jdecode(''),'/7342/index.html','true',[ 
		['PAGE','7363',jdecode('Assets'),jdecode(''),'/7342/7363.html','true',[],'',''],
		['PAGE','7384',jdecode('Business'),jdecode(''),'/7342/7384.html','true',[],'',''],
		['PAGE','7405',jdecode('Maintenance'),jdecode(''),'/7342/7405.html','true',[],'',''],
		['PAGE','7426',jdecode('Operations'),jdecode(''),'/7342/7426.html','true',[],'',''],
		['PAGE','7447',jdecode('Production'),jdecode(''),'/7342/7447.html','true',[],'',''],
		['PAGE','7468',jdecode('Staffing'),jdecode(''),'/7342/7468.html','true',[],'','']
	],'','']];
var siteelementCount=35;
theSitetree.topTemplateName='Blast';
theSitetree.paletteFamily='87C82A';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='33266';
theSitetree.graphicsetId='14145';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FFFFFF';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Blast',
				paletteFamily: 	'87C82A',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'33266',
				graphicsetId: 	'14145',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				a_color: 		'089D04',
				b_color: 		'84D66E',
				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:  '1601',
internalId:  '',
customField: '20100315-162019'
};
webappMappings['7008']=webappMappings['7008-3193']={
webappId:    '7008',
documentId:  '5701',
internalId:  '3193',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5143',
internalId:  '',
customField: '20100504-090420'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5701',
internalId:  '',
customField: '20100311-230823'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5101',
internalId:  '',
customField: '20100311-192205'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6401',
internalId:  '',
customField: '20100311-193203'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6601',
internalId:  '',
customField: '20100311-193516'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6701',
internalId:  '',
customField: '20100311-221902'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6901',
internalId:  '',
customField: '20100311-215846'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6922',
internalId:  '',
customField: '20100311-214703'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7048',
internalId:  '',
customField: '20100311-223622'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7216',
internalId:  '',
customField: '20100311-223457'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6943',
internalId:  '',
customField: '20100311-214930'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6964',
internalId:  '',
customField: '20100311-215142'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6985',
internalId:  '',
customField: '20100311-215436'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7006',
internalId:  '',
customField: '20100311-215630'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7027',
internalId:  '',
customField: '20100311-215817'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7069',
internalId:  '',
customField: '20100311-220125'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7090',
internalId:  '',
customField: '20100311-220453'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7111',
internalId:  '',
customField: '20100311-220629'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7132',
internalId:  '',
customField: '20100311-221031'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7153',
internalId:  '',
customField: '20100315-151010'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7174',
internalId:  '',
customField: '20100311-221428'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7195',
internalId:  '',
customField: '20100311-221546'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7237',
internalId:  '',
customField: '20100311-222551'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7258',
internalId:  '',
customField: '20100311-222852'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7279',
internalId:  '',
customField: '20100315-171935'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7300',
internalId:  '',
customField: '20100311-223309'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7321',
internalId:  '',
customField: '20100311-223422'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7342',
internalId:  '',
customField: '20100311-223637'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7363',
internalId:  '',
customField: '20100311-223742'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7384',
internalId:  '',
customField: '20100311-223927'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7405',
internalId:  '',
customField: '20100315-162807'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7426',
internalId:  '',
customField: '20100311-224400'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7447',
internalId:  '',
customField: '20100311-224513'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7468',
internalId:  '',
customField: '20100311-224647'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '1601',
internalId:  '1006',
customField: '1006'
};
var canonHostname = 'sitebuilder1.jnb2.host-h.net';
var accountId     = 'AHTZ10IN2MA5';
var companyName   = 'I-PAMS+++++++++++++++++Physical+Asset+Management+Systems';
var htmlTitle	  = '';
var metaKeywords  = 'planned+maintenance+asset+register+pams+physical+management+pams+i-pam+instandhouding';
var metaContents  = 'physical+asset+management+systems';
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();
};
