/* [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','8601',jdecode('Home'),jdecode(''), jdecode('%2F8601.html'), 'true',[],'',''],
	['PAGE','27729',jdecode('Need+Light%3F+START+HERE'),jdecode(''), jdecode('%2F27729.html'), 'true',[],'',''],
	['PAGE','85243',jdecode('COOL%2FNEUTRAL%2FWARM+Tint%3F'),jdecode(''), jdecode('%2F85243.html'), 'true',[],'',''],
	['PAGE','14322',jdecode('EAGLETAC+Tactical+Lights'),jdecode(''), jdecode('%2F14322%2Findex.html'), 'true',[ 
		['PAGE','156371',jdecode('PN20a+%2F+PN20a2'),jdecode(''), jdecode('%2F14322%2F156371.html'), 'true',[],'',''],
		['PAGE','396382',jdecode('D25+Series'),jdecode(''), jdecode('%2F14322%2F396382.html'), 'true',[],'',''],
		['PAGE','119357',jdecode('P10A'),jdecode(''), jdecode('%2F14322%2F119357.html'), 'false',[],'',''],
		['PAGE','23450',jdecode('P100A2'),jdecode(''), jdecode('%2F14322%2F23450.html'), 'true',[],'',''],
		['PAGE','26929',jdecode('P20A2+MKII'),jdecode(''), jdecode('%2F14322%2F26929.html'), 'true',[],'',''],
		['PAGE','142571',jdecode('P100C2'),jdecode(''), jdecode('%2F14322%2F142571.html'), 'true',[],'',''],
		['PAGE','26950',jdecode('P20C2+MKII'),jdecode(''), jdecode('%2F14322%2F26950.html'), 'true',[],'',''],
		['PAGE','26971',jdecode('T100C2+MKII'),jdecode(''), jdecode('%2F14322%2F26971.html'), 'true',[],'',''],
		['PAGE','26992',jdecode('T20C2+MKII'),jdecode(''), jdecode('%2F14322%2F26992.html'), 'true',[],'',''],
		['PAGE','435882',jdecode('G25C2'),jdecode(''), jdecode('%2F14322%2F435882.html'), 'true',[],'',''],
		['PAGE','27013',jdecode('M3C4'),jdecode(''), jdecode('%2F14322%2F27013.html'), 'true',[],'','']
	],'',''],
	['PAGE','346382',jdecode('WEAPON+Lights'),jdecode(''), jdecode('%2F346382.html'), 'true',[],'',''],
	['PAGE','145071',jdecode('P60+Light%2FLamp+Modules'),jdecode(''), jdecode('%2F145071.html'), 'true',[],'',''],
	['PAGE','304782',jdecode('SOLARFORCE'),jdecode(''), jdecode('%2F304782.html'), 'true',[],'',''],
	['PAGE','354882',jdecode('ARMYTEK'),jdecode(''), jdecode('%2F354882.html'), 'false',[],'',''],
	['PAGE','358282',jdecode('FENIX'),jdecode(''), jdecode('%2F358282.html'), 'true',[],'',''],
	['PAGE','374482',jdecode('JETBEAM'),jdecode(''), jdecode('%2F374482.html'), 'true',[],'',''],
	['PAGE','354903',jdecode('KLARUS'),jdecode(''), jdecode('%2F354903.html'), 'true',[],'',''],
	['PAGE','241082',jdecode('LUMAPOWER'),jdecode(''), jdecode('%2F241082.html'), 'true',[],'',''],
	['PAGE','166282',jdecode('NITECORE'),jdecode(''), jdecode('%2F166282.html'), 'true',[],'',''],
	['PAGE','242782',jdecode('TERRALUX'),jdecode(''), jdecode('%2F242782.html'), 'true',[],'',''],
	['PAGE','355382',jdecode('THRUNITE'),jdecode(''), jdecode('%2F355382.html'), 'true',[],'',''],
	['PAGE','354924',jdecode('XENO'),jdecode(''), jdecode('%2F354924.html'), 'true',[],'',''],
	['PAGE','14301',jdecode('ZEBRALIGHT'),jdecode(''), jdecode('%2F14301%2Findex.html'), 'true',[ 
		['PAGE','243482',jdecode('H501+%2F+H501W+%2F+H501R'),jdecode(''), jdecode('%2F14301%2F243482.html'), 'false',[],'',''],
		['PAGE','319582',jdecode('SC51+%2F+SC51W'),jdecode(''), jdecode('%2F14301%2F319582.html'), 'true',[],'',''],
		['PAGE','273282',jdecode('H51+%2F+H51W'),jdecode(''), jdecode('%2F14301%2F273282.html'), 'true',[],'',''],
		['PAGE','414582',jdecode('Q50'),jdecode(''), jdecode('%2F14301%2F414582.html'), 'true',[],'',''],
		['PAGE','273303',jdecode('SC80+%2F+SC80W'),jdecode(''), jdecode('%2F14301%2F273303.html'), 'true',[],'',''],
		['PAGE','243545',jdecode('SC31+%2F+SC31W'),jdecode(''), jdecode('%2F14301%2F243545.html'), 'true',[],'',''],
		['PAGE','243566',jdecode('H31+%2F+H31W'),jdecode(''), jdecode('%2F14301%2F243566.html'), 'true',[],'',''],
		['PAGE','244782',jdecode('H60+%2F+H60W'),jdecode(''), jdecode('%2F14301%2F244782.html'), 'false',[],'',''],
		['PAGE','354482',jdecode('SC600+%2F+SC600W'),jdecode(''), jdecode('%2F14301%2F354482.html'), 'true',[],'',''],
		['PAGE','273324',jdecode('H600+%2F+H600W'),jdecode(''), jdecode('%2F14301%2F273324.html'), 'true',[],'','']
	],'',''],
	['PAGE','190782',jdecode('ICON+Lights'),jdecode(''), jdecode('%2F190782.html'), 'false',[],'',''],
	['PAGE','442682',jdecode('XTAR+-+Dive+Lights'),jdecode(''), jdecode('%2F442682.html'), 'true',[],'',''],
	['PAGE','23471',jdecode('Batteries+%26+Carriers'),jdecode(''), jdecode('%2F23471.html'), 'true',[],'',''],
	['PAGE','14343',jdecode('Battery+Chargers+%26+Testers'),jdecode(''), jdecode('%2F14343.html'), 'true',[],'',''],
	['PAGE','371282',jdecode('Lubricants+%26+Flashlight+Maint.'),jdecode(''), jdecode('%2F371282.html'), 'true',[],'',''],
	['PAGE','394382',jdecode('Light+Holster+%2F+Case'),jdecode(''), jdecode('%2F394382.html'), 'true',[],'',''],
	['PAGE','10601',jdecode('Battery+FAQ'),jdecode(''), jdecode('%2F10601.html'), 'false',[],'',''],
	['PAGE','18650',jdecode('Water+Purification%2FFiltration'),jdecode(''), jdecode('%2F18650%2Findex.html'), 'true',[ 
		['PAGE','99057',jdecode('Water+Bottles'),jdecode(''), jdecode('%2F18650%2F99057.html'), 'true',[],'',''],
		['PAGE','99099',jdecode('Microfilter+%26+MicroPur'),jdecode(''), jdecode('%2F18650%2F99099.html'), 'true',[],'','']
	],'',''],
	['PAGE','131357',jdecode('Product+Reviews+%26+Press'),jdecode(''), jdecode('%2F131357.html'), 'false',[],'',''],
	['PAGE','14448',jdecode('Garage+Sale+%2F+Bargain+Bin'),jdecode(''), jdecode('%2F14448.html'), 'true',[],'',''],
	['PAGE','10622',jdecode('Resource+Links'),jdecode(''), jdecode('%2F10622.html'), 'true',[],'',''],
	['PAGE','102757',jdecode('International+Shipping'),jdecode(''), jdecode('%2F102757.html'), 'true',[],'',''],
	['PAGE','140471',jdecode('Customer+Testimonials'),jdecode(''), jdecode('%2F140471.html'), 'true',[],'',''],
	['PAGE','26429',jdecode('Contact+%2F+About+Us'),jdecode(''), jdecode('%2F26429.html'), 'true',[],'',''],
	['PAGE','120057',jdecode('ALL+Products'),jdecode(''), jdecode('%2F120057.html'), 'false',[],'','']];
var siteelementCount=55;
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 prodDef={
  wl_name: 'endurance',
  product: 'WSCSYSSSSLY0XRN4'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Solid',
				paletteFamily: 	'8396BA',
				keyvisualId: 	'4356',
				keyvisualName: 	'kv_4356.jpg',
				fontsetId: 		'10800',
				graphicsetId: 	'11232',
				contentColor: 	'000000',
				contentBGColor: '8396BA',
				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: '20120128-185524'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '119357',
internalId:  '',
customField: '20100215-094239'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '18650',
internalId:  '',
customField: '20111226-162047'
};
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: '20111226-163811'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '354882',
internalId:  '',
customField: '20110722-123550'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14448',
internalId:  '',
customField: '20110715-212855'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14301',
internalId:  '',
customField: '20111215-120729'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14322',
internalId:  '',
customField: '20120127-104101'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14343',
internalId:  '',
customField: '20120112-172804'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23471',
internalId:  '',
customField: '20120206-155830'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23450',
internalId:  '',
customField: '20120105-102811'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '241082',
internalId:  '',
customField: '20120117-210238'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '242782',
internalId:  '',
customField: '20110730-220702'
};
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: '20110428-132054'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26929',
internalId:  '',
customField: '20111221-192915'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26950',
internalId:  '',
customField: '20120103-092345'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26971',
internalId:  '',
customField: '20120105-102931'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26992',
internalId:  '',
customField: '20120203-131727'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27013',
internalId:  '',
customField: '20120117-210436'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '355382',
internalId:  '',
customField: '20111226-155514'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '243482',
internalId:  '',
customField: '20101210-133009'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '27729',
internalId:  '',
customField: '20100618-105040'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '319582',
internalId:  '',
customField: '20120206-135847'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '85243',
internalId:  '',
customField: '20120203-130625'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '99057',
internalId:  '',
customField: '20111024-143628'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '304782',
internalId:  '',
customField: '20120203-111353'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '99099',
internalId:  '',
customField: '20110925-205108'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102757',
internalId:  '',
customField: '20111208-093700'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '243566',
internalId:  '',
customField: '20120206-135121'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '120057',
internalId:  '',
customField: '20091105-214901'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '131357',
internalId:  '',
customField: '20100328-155155'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '354924',
internalId:  '',
customField: '20120203-111801'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '354903',
internalId:  '',
customField: '20120113-173752'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '243545',
internalId:  '',
customField: '20120206-135320'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '140471',
internalId:  '',
customField: '20110720-131100'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '142571',
internalId:  '',
customField: '20120122-200437'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '145071',
internalId:  '',
customField: '20111226-153200'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '156371',
internalId:  '',
customField: '20120105-103025'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '166282',
internalId:  '',
customField: '20120116-134256'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '190782',
internalId:  '',
customField: '20120124-170420'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '346382',
internalId:  '',
customField: '20120109-205224'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '273282',
internalId:  '',
customField: '20120206-135638'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '244782',
internalId:  '',
customField: '20110715-204819'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '273303',
internalId:  '',
customField: '20120206-135524'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '273324',
internalId:  '',
customField: '20120206-134930'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '354482',
internalId:  '',
customField: '20120206-135033'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '358282',
internalId:  '',
customField: '20120113-211447'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '371282',
internalId:  '',
customField: '20111226-161536'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '374482',
internalId:  '',
customField: '20120203-173028'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '394382',
internalId:  '',
customField: '20111022-143839'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '396382',
internalId:  '',
customField: '20120122-200334'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '414582',
internalId:  '',
customField: '20120112-172437'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '435882',
internalId:  '',
customField: '20120201-180610'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '442682',
internalId:  '',
customField: '20120103-092922'
};
var webAppHostname = 'cgiwsc.enhancedsitebuilder.com:80';
var canonHostname = 'cmworker01.yourhostingaccount.com';
var accountId     = 'AENDU0IN3P7S';
var companyName   = 'illuminationGear+-+Tactical+%26+Professional+Tools';
var htmlTitle	  = 'illuminationGear+-+Tactical+%26+Professional+Tools';
var metaKeywords  = 'illumination+gear%2C+illumination+tool%2Ctactical+light%2C+tactical+flashlights%2Ceagletac%2Ceagletac-store%2Ceagletac+store%2Czts%2Cbest+flashlight%2Cbest+professional+flashlights%2Cbest+tactical+flashlight%2Cbright+flashlight%2Cillumination+tool%2Cbest+tactical+flashlight%2Cweapon+light%2Ctactical+flashlight%2Cpolice+light%2Cpolice+flashlight%2Cthrunite%2Czebralight%2Cnitecore%2Cfenix%2Clumapower%2Cterralux%2Csolarforce%2Cspiderfire%2Czebralight+store%2Cpila+ibc%2Cpila+ibc+charger%2Cbest+batteries%2Ceneloops%2Cbest+flashlight%2Cbest+prices%2Cmaxpedition%2Ckatadyn%2Ckatadyn+exstream%2C+best+water+filter';
var metaContents  = 'Flashlight+%2F+Light+%2F+Tactical+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();
};

