/* [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 theSitetree=[ 
	['PAGE','8601',jdecode('Home'),jdecode(''),'/8601.html','true',[],''],
	['PAGE','27729',jdecode('Need+Light%3F+START+HERE'),jdecode(''),'/27729.html','true',[],''],
	['PAGE','85243',jdecode('COOL%2FNEUTRAL%2FWARM+Tint%3F'),jdecode(''),'/85243.html','true',[],''],
	['PAGE','14322',jdecode('EAGLETAC+Tactical+Lights'),jdecode(''),'/14322/index.html','true',[ 
		['PAGE','156371',jdecode('PN20a+%2F+PN20a2'),jdecode(''),'/14322/156371.html','true',[],''],
		['PAGE','119357',jdecode('P10A'),jdecode(''),'/14322/119357.html','false',[],''],
		['PAGE','172882',jdecode('PC20A+%2F+PC20A2'),jdecode(''),'/14322/172882.html','false',[],''],
		['PAGE','23450',jdecode('P100A2'),jdecode(''),'/14322/23450.html','true',[],''],
		['PAGE','26929',jdecode('P20A2+MKII'),jdecode(''),'/14322/26929.html','true',[],''],
		['PAGE','142571',jdecode('P100C2'),jdecode(''),'/14322/142571.html','true',[],''],
		['PAGE','171282',jdecode('PC20C+%2F+PC20C2'),jdecode(''),'/14322/171282.html','false',[],''],
		['PAGE','26950',jdecode('P20C2+MKII'),jdecode(''),'/14322/26950.html','true',[],''],
		['PAGE','170982',jdecode('TP20C2'),jdecode(''),'/14322/170982.html','false',[],''],
		['PAGE','26971',jdecode('T100C2+MKII+WPN+Light'),jdecode(''),'/14322/26971.html','true',[],''],
		['PAGE','26992',jdecode('T20C2+MKII+WPN+Light'),jdecode(''),'/14322/26992.html','true',[],''],
		['PAGE','72543',jdecode('M2SC4+MKII'),jdecode(''),'/14322/72543.html','true',[],''],
		['PAGE','27034',jdecode('M2XC4+MKII'),jdecode(''),'/14322/27034.html','true',[],''],
		['PAGE','27013',jdecode('M2C4'),jdecode(''),'/14322/27013.html','true',[],'']
	],''],
	['PAGE','166282',jdecode('NITECORE+Flashlights'),jdecode(''),'/166282.html','false',[],''],
	['PAGE','145071',jdecode('P60+Drop+in+Light+Module'),jdecode(''),'/145071.html','true',[],''],
	['PAGE','190782',jdecode('Surefire+ICON+Lights'),jdecode(''),'/190782.html','true',[],''],
	['PAGE','14301',jdecode('ZEBRALIGHT+Lights'),jdecode(''),'/14301/index.html','true',[ 
		['PAGE','39729',jdecode('H501+%2F+H501W'),jdecode(''),'/14301/39729.html','true',[],''],
		['PAGE','24529',jdecode('H501R+%28Red%29'),jdecode(''),'/14301/24529.html','true',[],''],
		['PAGE','184982',jdecode('H51+%2F+H51W'),jdecode(''),'/14301/184982.html','false',[],''],
		['PAGE','184082',jdecode('SC50+%2F+SC50W'),jdecode(''),'/14301/184082.html','true',[],''],
		['PAGE','138071',jdecode('SC30+%2F+SC30W'),jdecode(''),'/14301/138071.html','true',[],''],
		['PAGE','24550',jdecode('H60+%2F+H60W'),jdecode(''),'/14301/24550.html','true',[],'']
	],''],
	['PAGE','14343',jdecode('Batteries%2C+Testers%2C+Chargers'),jdecode(''),'/14343/index.html','true',[ 
		['PAGE','23471',jdecode('Batteries+%26+Cells'),jdecode(''),'/14343/23471.html','true',[],'']
	],''],
	['PAGE','10601',jdecode('Battery+FAQ'),jdecode(''),'/10601.html','false',[],''],
	['PAGE','18650',jdecode('Water+Purification%2FFiltration'),jdecode(''),'/18650/index.html','true',[ 
		['PAGE','99057',jdecode('Water+Bottles'),jdecode(''),'/18650/99057.html','true',[],''],
		['PAGE','99099',jdecode('Microfilter+%26+MicroPur'),jdecode(''),'/18650/99099.html','true',[],'']
	],''],
	['PAGE','131357',jdecode('Product+Reviews+%26+Press'),jdecode(''),'/131357.html','true',[],''],
	['PAGE','14448',jdecode('Garage+Sale+%2F+Bargain+Bin'),jdecode(''),'/14448.html','true',[],''],
	['PAGE','10622',jdecode('Resource+Links'),jdecode(''),'/10622.html','true',[],''],
	['PAGE','102757',jdecode('International+Shipping'),jdecode(''),'/102757.html','true',[],''],
	['PAGE','140471',jdecode('Customer+Testimonials'),jdecode(''),'/140471.html','true',[],''],
	['PAGE','26429',jdecode('Contact+%2F+About+Us'),jdecode(''),'/26429.html','true',[],''],
	['PAGE','18629',jdecode('Pack+%2F+Carry'),jdecode(''),'/18629.html','false',[],''],
	['PAGE','120057',jdecode('ALL+Products'),jdecode(''),'/120057.html','false',[],'']];
var siteelementCount=42;
theSitetree.topTemplateName='Solid';
theSitetree.paletteFamily='8396BA';
theSitetree.keyvisualId='4356';
theSitetree.keyvisualName='kv_4356.jpg';
theSitetree.fontsetId='10800';
theSitetree.graphicsetId='11232';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='8396BA';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				name: 			'Solid',
				paletteFamily: 	'8396BA',
				keyvisualId: 	'4356',
				keyvisualName: 	'kv_4356.jpg',
				fontsetId: 		'10800',
				graphicsetId: 	'11232',
				contentColor: 	'000000',
				contentBGColor: '8396BA',
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'false',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'true'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8601',
internalId:  '',
customField: '20100304-082243'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '119357',
internalId:  '',
customField: '20100215-094239'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '18629',
internalId:  '',
customField: '20090812-223335'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '18650',
internalId:  '',
customField: '20100117-132719'
};
webappMappings['1501']=webappMappings['1501-20984318']={
webappId:    '1501',
documentId:  '8601',
internalId:  '20984318',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10601',
internalId:  '',
customField: '20091028-171618'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10622',
internalId:  '',
customField: '20100307-130150'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '171282',
internalId:  '',
customField: '20100203-200615'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14448',
internalId:  '',
customField: '20091210-143811'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14301',
internalId:  '',
customField: '20100216-224419'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14322',
internalId:  '',
customField: '20100224-212447'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14343',
internalId:  '',
customField: '20100223-223915'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '24529',
internalId:  '',
customField: '20100216-224308'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23471',
internalId:  '',
customField: '20100309-194215'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23450',
internalId:  '',
customField: '20100211-083727'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '184982',
internalId:  '',
customField: '20100206-152800'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '24550',
internalId:  '',
customField: '20100216-224059'
};
webappMappings['7008']=webappMappings['7008-19829']={
webappId:    '7008',
documentId:  '26429',
internalId:  '19829',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26429',
internalId:  '',
customField: '20100106-131149'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26929',
internalId:  '',
customField: '20100309-195559'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26950',
internalId:  '',
customField: '20100309-195735'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26971',
internalId:  '',
customField: '20100309-200007'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26992',
internalId:  '',
customField: '20100309-194834'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27013',
internalId:  '',
customField: '20100209-194504'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27034',
internalId:  '',
customField: '20100209-194621'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '39729',
internalId:  '',
customField: '20100216-224344'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27729',
internalId:  '',
customField: '20100127-204330'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '72543',
internalId:  '',
customField: '20100209-194735'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '85243',
internalId:  '',
customField: '20100127-204119'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '99057',
internalId:  '',
customField: '20100106-130802'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '99099',
internalId:  '',
customField: '20100209-193856'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102757',
internalId:  '',
customField: '20091118-105136'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '184082',
internalId:  '',
customField: '20100304-085004'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '120057',
internalId:  '',
customField: '20091105-214901'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '131357',
internalId:  '',
customField: '20100129-231023'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '170982',
internalId:  '',
customField: '20100203-201101'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '172882',
internalId:  '',
customField: '20100225-130239'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '138071',
internalId:  '',
customField: '20100216-224133'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '140471',
internalId:  '',
customField: '20091210-145818'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '142571',
internalId:  '',
customField: '20100222-213945'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '145071',
internalId:  '',
customField: '20100301-220502'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '156371',
internalId:  '',
customField: '20100210-220103'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '166282',
internalId:  '',
customField: '20100129-054422'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '190782',
internalId:  '',
customField: '20100217-200842'
};
var canonHostname = 'cmworker02.yourhostingaccount.com';
var accountId     = 'AENDU0IN3P7S';
var companyName   = 'Illumination+Gear+%26+Outdoor+Products';
var htmlTitle	  = 'Best+Illumination+Gear+%26+Outdoor+Products';
var metaKeywords  = 'illumination+gear%2C+illumination+tool%2Ceagletac%2Ceagletac-store%2Ceagletac+store%2Czts%2Cbest+flashlight%2Cbest+professional+flashlights%2Cbest+tactical+flashlight%2Cbright+flashlight%2Cillumination+tool%2Cbest+tactical+flashlight%2Ctactical+flashlight%2Cpolice+light%2Cpolice+flashlight%2Czebralight%2Czebralight+store%2Cpila+ibc%2Cpila+ibc+charger%2Cbest+batteries%2Ceneloops%2Cbest+flashlight%2Cbest+prices%2Cmaxpedition%2Ckatadyn%2Ckatadyn+exstream%2C+best+water+filter';
var metaContents  = 'Products+for+Police%2C+Law+Enforcement%2C+Search++Rescue%2C+Military%2C+Survival%2C+Travelers%2C+Outdoor+Enthusiasts%2C+Camping-Backpacking.';
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();
};
