/* [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','4597',jdecode('Home'),jdecode(''),'/4597.html','true',[],'',''],
	['PAGE','48601',jdecode('Monthly+Feature'),jdecode(''),'/48601.html','true',[],'',''],
	['PAGE','33317',jdecode('New+Products'),jdecode(''),'/33317.html','true',[],'',''],
	['PAGE','30326',jdecode('Specials'),jdecode(''),'/30326.html','true',[],'',''],
	['PAGE','9026',jdecode('Promotional+Products'),jdecode(''),'/9026/index.html','true',[ 
		['PAGE','9053',jdecode('Pens'),jdecode(''),'/9026/9053.html','true',[],'',''],
		['PAGE','9107',jdecode('Bags'),jdecode(''),'/9026/9107.html','true',[],'',''],
		['PAGE','9134',jdecode('Umbrellas'),jdecode(''),'/9026/9134.html','true',[],'',''],
		['PAGE','9188',jdecode('General'),jdecode(''),'/9026/9188.html','true',[],'','']
	],'',''],
	['PAGE','21412',jdecode('Apparel'),jdecode(''),'/21412/index.html','true',[ 
		['PAGE','9080',jdecode('T-shirts'),jdecode(''),'/21412/9080.html','true',[],'',''],
		['PAGE','22112',jdecode('Polos'),jdecode(''),'/21412/22112.html','true',[],'',''],
		['PAGE','34291',jdecode('Shirts'),jdecode(''),'/21412/34291.html','true',[],'',''],
		['PAGE','22139',jdecode('Fleece'),jdecode(''),'/21412/22139.html','true',[],'',''],
		['PAGE','22166',jdecode('Jackets'),jdecode(''),'/21412/22166.html','true',[],'',''],
		['PAGE','9161',jdecode('Headwear'),jdecode(''),'/21412/9161.html','true',[],'',''],
		['PAGE','43401',jdecode('Customised+Caps'),jdecode(''),'/21412/43401.html','true',[],'',''],
		['PAGE','39501',jdecode('Eco+Apparel'),jdecode(''),'/21412/39501.html','true',[],'','']
	],'',''],
	['PAGE','13627',jdecode('Gift+Ideas'),jdecode(''),'/13627/index.html','true',[ 
		['PAGE','26812',jdecode('Under+%24+10+Ideas'),jdecode(''),'/13627/26812.html','true',[],'',''],
		['PAGE','13654',jdecode('%24+10+-+%24+20+Ideas'),jdecode(''),'/13627/13654.html','true',[],'',''],
		['PAGE','13681',jdecode('%24+20+-+%24+30+Ideas+'),jdecode(''),'/13627/13681.html','true',[],'',''],
		['PAGE','13708',jdecode('%24+30+-+%24+50+Ideas'),jdecode(''),'/13627/13708.html','true',[],'',''],
		['PAGE','27434',jdecode('%24+50%2B+Ideas'),jdecode(''),'/13627/27434.html','true',[],'',''],
		['PAGE','34005',jdecode('Bag+Gift+Ideas'),jdecode(''),'/13627/34005.html','true',[],'',''],
		['PAGE','34014',jdecode('Beach+Gift+Ideas'),jdecode(''),'/13627/34014.html','true',[],'',''],
		['PAGE','34023',jdecode('Entertainment+Gift+Ideas'),jdecode(''),'/13627/34023.html','true',[],'',''],
		['PAGE','34032',jdecode('Office+Gift+Ideas'),jdecode(''),'/13627/34032.html','true',[],'',''],
		['PAGE','34041',jdecode('Personal+Gift+Ideas'),jdecode(''),'/13627/34041.html','true',[],'',''],
		['PAGE','33722',jdecode('Packaging'),jdecode(''),'/13627/33722.html','true',[],'','']
	],'',''],
	['PAGE','9242',jdecode('Factory+Direct'),jdecode(''),'/9242.html','true',[],'',''],
	['PAGE','18823',jdecode('Case+Studies'),jdecode(''),'/18823/index.html','true',[ 
		['PAGE','33806',jdecode('General+Products'),jdecode(''),'/18823/33806.html','true',[],'',''],
		['PAGE','33797',jdecode('Clothing+%26+Headwear'),jdecode(''),'/18823/33797.html','true',[],'',''],
		['PAGE','33815',jdecode('Corporate+Gifts'),jdecode(''),'/18823/33815.html','true',[],'',''],
		['PAGE','33824',jdecode('Indent+Items'),jdecode(''),'/18823/33824.html','true',[],'','']
	],'',''],
	['PAGE','29332',jdecode('Online+Catalogues'),jdecode(''),'/29332.html','true',[],'',''],
	['PAGE','9269',jdecode('Contact+Zest'),jdecode(''),'/9269.html','true',[],'','']];
var siteelementCount=38;
theSitetree.topTemplateName='Linedup';
theSitetree.paletteFamily='FFFFFF';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10359';
theSitetree.graphicsetId='10509';
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: 			'Linedup',
				paletteFamily: 	'FFFFFF',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10359',
				graphicsetId: 	'10509',
				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:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '4597',
internalId:  '',
customField: '20100531-230752'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '48601',
internalId:  '',
customField: '20100531-231911'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33317',
internalId:  '',
customField: '20100531-232029'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '30326',
internalId:  '',
customField: '20100531-232151'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9026',
internalId:  '',
customField: '20100208-222217'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9188',
internalId:  '',
customField: '20090803-210114'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29332',
internalId:  '',
customField: '20090907-221312'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13627',
internalId:  '',
customField: '20091004-010406'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26812',
internalId:  '',
customField: '20091004-011629'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13654',
internalId:  '',
customField: '20091004-011731'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13681',
internalId:  '',
customField: '20091004-012240'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13708',
internalId:  '',
customField: '20091004-012322'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27434',
internalId:  '',
customField: '20091004-012402'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34005',
internalId:  '',
customField: '20091106-173414'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34014',
internalId:  '',
customField: '20091106-173505'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34023',
internalId:  '',
customField: '20091106-173551'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34032',
internalId:  '',
customField: '20091106-173625'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34041',
internalId:  '',
customField: '20091106-174224'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33722',
internalId:  '',
customField: '20090603-190602'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '21412',
internalId:  '',
customField: '20070403-233839'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9080',
internalId:  '',
customField: '20080720-164305'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22112',
internalId:  '',
customField: '20080720-164431'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '34291',
internalId:  '',
customField: '20071212-184942'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22139',
internalId:  '',
customField: '20080720-164633'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22166',
internalId:  '',
customField: '20080720-164038'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9161',
internalId:  '',
customField: '20090421-164212'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '43401',
internalId:  '',
customField: '20080406-203608'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '39501',
internalId:  '',
customField: '20080604-005510'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9053',
internalId:  '',
customField: '20100531-194411'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9107',
internalId:  '',
customField: '20100531-213032'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9134',
internalId:  '',
customField: '20100527-183956'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9242',
internalId:  '',
customField: '20071212-180516'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '18823',
internalId:  '',
customField: '20071009-144452'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33806',
internalId:  '',
customField: '20071009-150330'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33797',
internalId:  '',
customField: '20071009-150146'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33815',
internalId:  '',
customField: '20071009-150451'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33824',
internalId:  '',
customField: '20071009-150911'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9269',
internalId:  '',
customField: '20090507-174931'
};
var canonHostname = 'diywk00.verio.stngva01.us.diy-servers.net';
var accountId     = 'AVEC10IN2G2I';
var companyName   = 'BRINGING+YOU+FRESH+PROMOTIONAL+IDEAS';
var htmlTitle	  = 'Zest+Promotions+-+Bringing+You+Fresh+Promotional+Ideas';
var metaKeywords  = 'promotional+products%2C+corporate+gifts%2C+sales+promotions%2C+marketing%2C+promotions%2C+zest%2C+zest+promotions%2C+premiums%2C+sourcing%2C+branding%2C+customised';
var metaContents  = 'Zest+Promotions+brings+you+fresh+promotional+ideas.++Were+here+to+take+the+hassle+out+of+your+promotional+marketing.++Whether+it+is+branded+merchandise%2C+client+%2F+staff+gifts%2C+conference+items+or+promotional+campaigns+we+can+develop+innovative+products+and+creative+solutions+relevant+to+your+brand+values+and+target+market.';
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();
};
