/* [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','7101',jdecode('Home'),jdecode(''), jdecode('%2F7101.html'), 'true',[],'',''],
	['PAGE','2152',jdecode('About+Our+Firm'),jdecode(''), jdecode('%2F2152.html'), 'true',[],'',''],
	['PAGE','2341',jdecode('Our+Attorneys'),jdecode(''), jdecode('%2F2341.html'), 'true',[],'',''],
	['PAGE','2173',jdecode('Our+Areas+of+Practice'),jdecode(''), jdecode('%2F2173%2Findex.html'), 'true',[ 
		['PAGE','2194',jdecode('Employment+Law'),jdecode(''), jdecode('%2F2173%2F2194.html'), 'true',[],'',''],
		['PAGE','2215',jdecode('Education+Law'),jdecode(''), jdecode('%2F2173%2F2215.html'), 'true',[],'',''],
		['PAGE','2236',jdecode('Civil+Rights'),jdecode(''), jdecode('%2F2173%2F2236.html'), 'true',[],'',''],
		['PAGE','2257',jdecode('Personal+Injury'),jdecode(''), jdecode('%2F2173%2F2257.html'), 'true',[],'',''],
		['PAGE','2278',jdecode('Arbitration'),jdecode(''), jdecode('%2F2173%2F2278.html'), 'true',[],'',''],
		['PAGE','2299',jdecode('ERISA+Appeals+and+Litigation'),jdecode(''), jdecode('%2F2173%2F2299.html'), 'true',[],'',''],
		['PAGE','2320',jdecode('CalPERS'),jdecode(''), jdecode('%2F2173%2F2320.html'), 'true',[],'','']
	],'',''],
	['PAGE','5301',jdecode('Employment+Law+Resources'),jdecode(''), jdecode('%2F5301.html'), 'true',[],'',''],
	['PAGE','2362',jdecode('Contact+Us'),jdecode(''), jdecode('%2F2362.html'), 'true',[],'','']];
var siteelementCount=13;
theSitetree.topTemplateName='Champagne';
theSitetree.paletteFamily='426388';
theSitetree.keyvisualId='11354';
theSitetree.keyvisualName='kv_11354.jpg';
theSitetree.fontsetId='31946';
theSitetree.graphicsetId='13786';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='426388';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'grp35-attweb',
  product: 'WSCSYSSSSLY0X9RC'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Champagne',
				paletteFamily: 	'426388',
				keyvisualId: 	'11354',
				keyvisualName: 	'kv_11354.jpg',
				fontsetId: 		'31946',
				graphicsetId: 	'13786',
				contentColor: 	'000000',
				contentBGColor: '426388',
				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:  '7101',
internalId:  '',
customField: '20111020-153432'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2152',
internalId:  '',
customField: '20100623-115532'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2173',
internalId:  '',
customField: '20100623-115952'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2194',
internalId:  '',
customField: '20100623-120938'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2215',
internalId:  '',
customField: '20100623-121217'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2236',
internalId:  '',
customField: '20100623-121600'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2257',
internalId:  '',
customField: '20100623-121948'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2278',
internalId:  '',
customField: '20100623-122121'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2299',
internalId:  '',
customField: '20100623-123607'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2320',
internalId:  '',
customField: '20100623-123734'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2341',
internalId:  '',
customField: '20111027-155300'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2362',
internalId:  '',
customField: '20110714-145328'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5301',
internalId:  '',
customField: '20110714-175433'
};
webappMappings['7050']=webappMappings['7050-7738']={
webappId:    '7050',
documentId:  '7101',
internalId:  '7738',
customField: 'language:en;country:US;'
};
var webAppHostname = 'diycgi.cluster.stngva01.us.diy-servers.net:80';
var canonHostname = 'diywk01.verio.stngva01.us.diy-servers.net';
var accountId     = 'AVF340I7CPES';
var companyName   = 'Law+Offices+of+John+F.+Martin%2C+P.C.+++++++++++++++++++++++++++++++++++++++++++++++++925-937-5433';
var htmlTitle	  = 'Employment+Lawyer%2C+Walnut+Creek%2C+Civil+Rights%2C+Education%2C+Disability%2C+Wrongful+Termination+Attorney%2C+Bay+Area';
var metaKeywords  = 'EMPLOYMENT+LAWYER%2C+EDUCATION+LAWYER%2C+CIVIL+RIGHTS+LAWYER%2C+WALNUT+CREEK%2C+BAY+AREA%2C+Law+Offices+of+John+F.+Martin%2C+P.C.++employment+law+education+law+and+civil+rights+firm+in+Walnut+Creek%2C+CA++california%2C+john+f.+martin%2C+christine+hopkins%2C+denise+cardoso%2C++employee+employer+discrimination+harassment+wrongful+termination+retaliation+disability+reasonable+accommodations+overtime+unpaid+wages+ERISA+CalPERS+benefits+COBRA+Plaintiff+personal+injury+employment+contract++health+insurance+pension+retirement%2C++Lafayette%2C+Orinda%2C+Concord%2C+Pleasant+Hill%2C+Martinez%2C+Benicia%2C+Oakland%2C+Emeryville%2C+Berkeley%2C+San+Francisco%2C+Fairfield%2C+Vacaville%2C+Suisun+City%2C+Vallejo%2C+Sacramento%2C+San+Jose%0D%0A%0D%0A%0D%0A%0D%0A%0D%0A%0D%0A%0D%0A%0D%0Aserving+East+Bay+Oakland%2C+CA++San+Francisco%2C+CA++Alameda+County%2C+Contra+Costa+County+Solano+County+Fairfield%2C+CA%2C+Sacramento%2C+Marin%2C+Toulumne+County%2C+San+Jose%2C+Fresno%2C+Modesto';
var metaContents  = 'EMPLOYMENT+LAWYER%2C+ATTORNEY%2C+EDUCATION+LAWYER%2C+CIVIL+RIGHTS+LAWYER%2C+WALNUT+CREEK%2C+BAY+AREA%2C+CALIFORNIA%2C+Law+Offices+of+John+F.+Martin%2C+P.C.%2C+An+employment+law%2C+education+law%2C+and+civil+rights+firm+in+Walnut+Creek%2C+CA%2C+serving+Alameda+County%2C+Contra+Costa+County%2C+San+Francisco%2C+Solano+County%2C+Sacramento+County.+Lafayette%2C+Orinda%2C+Concord%2C+Pleasant+Hill%2C+Martinez%2C+Benicia%2C+Oakland%2C+Emeryville%2C+Berkeley%2C+San+Francisco%2C+Fairfield%2C+Vacaville%2C+Suisun+City%2C+Vallejo%2C+Sacramento%2C+San+Jose.';
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();
};

