/* [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','6301',jdecode('Strona+g%C5%82%C3%B3wna'),jdecode(''),'/6301.html','true',[],'',''],
	['PAGE','8001',jdecode('Katalogi'),jdecode(''),'/8001.html','true',[],'',''],
	['PAGE','9201',jdecode('Cenniki'),jdecode(''),'/9201.html','true',[],'',''],
	['PAGE','10301',jdecode('Instrukcje+obs%C5%82ugi'),jdecode(''),'/10301.html','true',[],'',''],
	['PAGE','16201',jdecode('Ratownictwo+ekologiczne'),jdecode(''),'/16201.html','true',[],'',''],
	['PAGE','16222',jdecode('Ratownictwo+techniczne'),jdecode(''),'/16222.html','true',[],'',''],
	['PAGE','16243',jdecode('Nagrody+i+wyr%C3%B3%C5%BCnienia'),jdecode(''),'/16243.html','true',[],'',''],
	['PAGE','15301',jdecode('Jak+do+nas+trafi%C4%87'),jdecode(''),'/15301.html','true',[],'',''],
	['PAGE','15322',jdecode('Kontakt'),jdecode(''),'/15322.html','true',[],'',''],
	['PAGE','9501',jdecode('Linki'),jdecode(''),'/9501.html','true',[],'','']];
var siteelementCount=10;
theSitetree.topTemplateName='Movement';
theSitetree.paletteFamily='3E6E72';
theSitetree.keyvisualId='1737';
theSitetree.keyvisualName='blumen.jpg';
theSitetree.fontsetId='26898';
theSitetree.graphicsetId='354';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='3E6E72';
var localeDef={
  language: 'pl',
  country: 'PL'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Movement',
				paletteFamily: 	'3E6E72',
				keyvisualId: 	'1737',
				keyvisualName: 	'blumen.jpg',
				fontsetId: 		'26898',
				graphicsetId: 	'354',
				contentColor: 	'FFFFFF',
				contentBGColor: '3E6E72',
				a_color: 		'3E6E72',
				b_color: 		'101C1D',
				c_color: 		'FFFFFF',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'true',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'true'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6301',
internalId:  '',
customField: '20091203-223153'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8001',
internalId:  '',
customField: '20091203-233840'
};
webappMappings['1501']=webappMappings['1501-16257595']={
webappId:    '1501',
documentId:  '6301',
internalId:  '16257595',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9201',
internalId:  '',
customField: '20091207-105654'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9501',
internalId:  '',
customField: '20091203-133633'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10301',
internalId:  '',
customField: '20091207-110759'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '6301',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15301',
internalId:  '',
customField: '20091203-133451'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15322',
internalId:  '',
customField: '20091203-132952'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '16201',
internalId:  '',
customField: '20091203-224011'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '16222',
internalId:  '',
customField: '20091203-135345'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '16243',
internalId:  '',
customField: '20091203-140209'
};
var canonHostname = 'wsc2.home.net.pl';
var accountId     = 'AHPL10INPBRA';
var companyName   = 'PTH+%22COMPART%22-+Z.Dziembowski';
var htmlTitle	  = 'wodkan.info.pl+%3A++COMPART+-+Z.Dziembowski+-+Gliwice++%28+sava+-+vetter+-+zumro+-+resqtec+%29';
var metaKeywords  = 'korki+pneumatyczne%2C+korki%2C+pakery%2C+poduszki+pneumatyczne%2C+SAVA%2C+SAVATECH%2C+VETTER%2C+RESQTEC%2C+ZUMRO%2C+wodoci%C4%85gi%2C+kanalizacja%2C+wodkan%2C+wod-kan%2C+RDK%2C+PDK%2C+PLUGY%2C+PLUGSY%2C+Lampe%2C+Vepro%2C+Rubena%2C+Compart%2C+Dziembowski%2C+Gliwice%2C+korek%2C+paker%2C+poduszka';
var metaContents  = 'Na+za%C5%82%C4%85czonych+stronach+zamieszczamy+informacje+w+temacie+pneumatycznych+poduszek+i+kork%C3%B3w.+Jest+to+temat%2C+kt%C3%B3ry+zg%C5%82%C4%99biamy+od+chwili%2C+gdy+w+1992+roku+uzyskali%C5%9Bmy+na+terenie+Polski+przedstawicielstwo+firmy+Manfred+Vetter+GmbH.+Od+roku+2004+rozszerzyli%C5%9Bmy+nasz%C4%85+dzia%C5%82alno%C5%9B%C4%87+o+dystrybucj%C4%99+i+serwis+pneumatycznego+sprz%C4%99tu+firmy+SAVA+posiadaj%C4%85cej+opr%C3%B3cz+pneumatycznego+sprz%C4%99tu+ratownictwa+drogowego+i+ekologicznego+tak%C5%BCe+bardzo+szerok%C4%85+ofert%C4%99+pneumatycznych+kork%C3%B3w+i+paker%C3%B3w+dla+kanalizacji.+W+roku+2005+wzbogacili%C5%9Bmy+nasz%C4%85+ofert%C4%99+o+przedstawicielstwo+firmy+RESQTEC+%E2%80%93+ZUMRO+B.V.%2C+kt%C3%B3ra+jest+jednym+z+najwa%C5%BCniejszych+producent%C3%B3w+hydraulicznego+i+pneumatycznego+sprz%C4%99tu+ratowniczego+na+%C5%9Bwiecie.';
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();
};

