/* [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','501',jdecode('WELCOME+'),jdecode(''), jdecode('%2F501.html'), 'true',[],'',''],
	['PAGE','701',jdecode('Who+We+Are+'),jdecode(''), jdecode('%2F701.html'), 'true',[],'',''],
	['PAGE','722',jdecode('Directors'),jdecode(''), jdecode('%2F722.html'), 'true',[],'',''],
	['PAGE','743',jdecode('Membership+Benefits'),jdecode(''), jdecode('%2F743%2Findex.html'), 'true',[ 
		['PAGE','764',jdecode('Join+Today'),jdecode(''), jdecode('%2F743%2F764.html'), 'true',[],'',''],
		['PAGE','7501',jdecode('CAF'),jdecode(''), jdecode('%2F743%2F7501.html'), 'true',[],'',''],
		['PAGE','806',jdecode('Agent%26%23x27%3Bs+LDF'),jdecode(''), jdecode('%2F743%2F806.html'), 'false',[],'',''],
		['PAGE','785',jdecode('Agent%26%23x27%3Bs+E%260'),jdecode(''), jdecode('%2F743%2F785.html'), 'true',[],'','']
	],'',''],
	['PAGE','932',jdecode('Continuing+Ed+'),jdecode(''), jdecode('%2F932%2Findex.html'), 'true',[ 
		['PAGE','953',jdecode('AT+CONVENTION'),jdecode(''), jdecode('%2F932%2F953.html'), 'true',[],'',''],
		['PAGE','995',jdecode('At+Convention'),jdecode(''), jdecode('%2F932%2F995.html'), 'false',[],'',''],
		['PAGE','1016',jdecode('By+Mail'),jdecode(''), jdecode('%2F932%2F1016.html'), 'false',[],'',''],
		['PAGE','974',jdecode('Online+'),jdecode(''), jdecode('%2F932%2F974.html'), 'true',[],'','']
	],'',''],
	['PAGE','848',jdecode('Trade+Fair+'),jdecode(''), jdecode('%2F848%2Findex.html'), 'true',[ 
		['PAGE','827',jdecode('Registration+Agent'),jdecode(''), jdecode('%2F848%2F827.html'), 'true',[],'',''],
		['PAGE','5801',jdecode('Registration+Exibitor'),jdecode(''), jdecode('%2F848%2F5801.html'), 'true',[],'',''],
		['PAGE','180554',jdecode('TRADE+FAIR+PICTURES'),jdecode(''), jdecode('%2F848%2F180554.html'), 'false',[],'','']
	],'',''],
	['PAGE','38901',jdecode('Onsite+Registration'),jdecode(''), jdecode('%2F38901.html'), 'false',[],'',''],
	['PAGE','9501',jdecode('Legislative'),jdecode(''), jdecode('%2F9501%2Findex.html'), 'true',[ 
		['PAGE','15101',jdecode('Florida+Senate'),jdecode(''), jdecode('%2F9501%2F15101.html'), 'true',[],'',''],
		['PAGE','15122',jdecode('Florida+House'),jdecode(''), jdecode('%2F9501%2F15122.html'), 'true',[],'',''],
		['PAGE','1037',jdecode('Legislative+Links'),jdecode(''), jdecode('%2F9501%2F1037.html'), 'true',[],'','']
	],'',''],
	['PAGE','869',jdecode('Unite+'),jdecode(''), jdecode('%2F869.html'), 'true',[],'',''],
	['PAGE','181954',jdecode('PHOTO+GALLERY'),jdecode(''), jdecode('%2F181954%2Findex.html'), 'true',[ 
		['PAGE','181975',jdecode('2010+CONVENTION'),jdecode(''), jdecode('%2F181954%2F181975.html'), 'true',[],'',''],
		['PAGE','179854',jdecode('2009+CONVENTION'),jdecode(''), jdecode('%2F181954%2F179854.html'), 'true',[],'','']
	],'',''],
	['PAGE','1079',jdecode('Photo+Gallery'),jdecode(''), jdecode('%2F1079.html'), 'false',[],'',''],
	['PAGE','890',jdecode('Calendar+of+Events'),jdecode(''), jdecode('%2F890%2Findex.html'), 'true',[ 
		['PAGE','911',jdecode('Past+Unite+Mag'),jdecode(''), jdecode('%2F890%2F911.html'), 'false',[],'','']
	],'',''],
	['PAGE','1100',jdecode('News+and+Updates'),jdecode(''), jdecode('%2F1100.html'), 'true',[],'',''],
	['PAGE','190014',jdecode('MAKE+MONEY+WITH+SA'),jdecode(''), jdecode('%2F190014.html'), 'true',[],'',''],
	['PAGE','162754',jdecode('+Blog+Page'),jdecode(''), jdecode('%2F162754.html'), 'true',[],'',''],
	['PAGE','1058',jdecode('Contact'),jdecode(''), jdecode('%2F1058.html'), 'true',[],'','']];
var siteelementCount=33;
theSitetree.topTemplateName='Orbit';
theSitetree.paletteFamily='003366';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='172';
theSitetree.graphicsetId='203';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='003366';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'hps_testtown',
  product: 'WSCSYSSSSLYTC24G'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Orbit',
				paletteFamily: 	'003366',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'172',
				graphicsetId: 	'203',
				contentColor: 	'FFFFFF',
				contentBGColor: '003366',
				a_color: 		'003366',
				b_color: 		'336699',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'false',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'true'
			  };
var webappMappings = {};
webappMappings['1501']=webappMappings['1501-2366479']={
webappId:    '1501',
documentId:  '501',
internalId:  '2366479',
customField: '1501'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '501',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '501',
internalId:  '',
customField: '20120124-165437'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1100',
internalId:  '',
customField: '20100730-153713'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '848',
internalId:  '',
customField: '20120124-165851'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '701',
internalId:  '',
customField: '20120124-164733'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '722',
internalId:  '',
customField: '20120124-165535'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '743',
internalId:  '',
customField: '20120124-165619'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '764',
internalId:  '',
customField: '20120124-165643'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '806',
internalId:  '',
customField: '20090821-135518'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7501',
internalId:  '',
customField: '20091217-150343'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '785',
internalId:  '',
customField: '20110211-111739'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '827',
internalId:  '',
customField: '20120124-165922'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5801',
internalId:  '',
customField: '20120124-165944'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '869',
internalId:  '',
customField: '20100730-144856'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '890',
internalId:  '',
customField: '20120124-170229'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '911',
internalId:  '',
customField: '20090310-043740'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '932',
internalId:  '',
customField: '20120124-141557'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '953',
internalId:  '',
customField: '20120124-141912'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '974',
internalId:  '',
customField: '20120124-142048'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '995',
internalId:  '',
customField: '20090821-144028'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1016',
internalId:  '',
customField: '20120124-165744'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1037',
internalId:  '',
customField: '20100730-143954'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9501',
internalId:  '',
customField: '20120124-165953'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15101',
internalId:  '',
customField: '20120124-170004'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15122',
internalId:  '',
customField: '20090723-185201'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1058',
internalId:  '',
customField: '20091112-075842'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1079',
internalId:  '',
customField: '20100427-155411'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '38901',
internalId:  '',
customField: '20090710-101823'
};
webappMappings['7050']=webappMappings['7050-1439']={
webappId:    '7050',
documentId:  '162754',
internalId:  '1439',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '162754',
internalId:  '',
customField: '20091217-161023'
};
webappMappings['7060']=webappMappings['7060-25fa55aec332f886fc1b82b47ff74476']={
webappId:    '7060',
documentId:  '179854',
internalId:  '25fa55aec332f886fc1b82b47ff74476',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '179854',
internalId:  '',
customField: '20100730-153410'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '180554',
internalId:  '',
customField: '20100730-132817'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '181954',
internalId:  '',
customField: '20100730-153546'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '181975',
internalId:  '',
customField: '20100730-151816'
};
webappMappings['7060']=webappMappings['7060-d21c5653b9eee0401bd16d3758a1680a']={
webappId:    '7060',
documentId:  '181975',
internalId:  'd21c5653b9eee0401bd16d3758a1680a',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '190014',
internalId:  '',
customField: '20110222-162753'
};
var webAppHostname = 'cgi-wsc.chi.us.siteprotect.com:80';
var canonHostname = 'wsc-worker03.chi.us.siteprotect.com';
var accountId     = 'AHW050INVQYE';
var companyName   = 'Specialty+Insurance+Agents+Association';
var htmlTitle	  = 'Specialty+Insurance+Agents+Association%2C+Inc.';
var metaKeywords  = 'Specialty+agents%2C+Insurance%2C+Florida%2C+Associations%2C+legislature%2C+Senate%2C+SA%2C+Specialty+Agents+of+Florida%2C+Specialty+Insurance+Agents+Association%2C+Unite';
var metaContents  = 'Website+for+Specialty+Insurance+Agents+Association%2C+Members%2C+and+Legislative+Members';
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();
};

