/* [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','8201',jdecode('Home'),jdecode(''),'/8201.html','true',[],'',''],
	['PAGE','8252',jdecode('About+us'),jdecode(''),'/8252.html','true',[],'',''],
	['PAGE','8273',jdecode('Artists'),jdecode(''),'/8273/index.html','true',[ 
		['PAGE','13801',jdecode('Sharon+Bartel-Clements'),jdecode(''),'/8273/13801.html','true',[],'',''],
		['PAGE','19701',jdecode('Rosetta+Bentz'),jdecode(''),'/8273/19701.html','true',[],'',''],
		['PAGE','48812',jdecode('Dorothy+Cochran'),jdecode(''),'/8273/48812.html','true',[],'',''],
		['PAGE','48833',jdecode('Elaine+Defibaugh'),jdecode(''),'/8273/48833.html','true',[],'',''],
		['PAGE','15501',jdecode('Laura+Duggan'),jdecode(''),'/8273/15501.html','true',[],'',''],
		['PAGE','8294',jdecode('Edward+Evans'),jdecode(''),'/8273/8294.html','true',[],'',''],
		['PAGE','18501',jdecode('About+the+Artist'),jdecode(''),'/8273/18501.html','true',[],'',''],
		['PAGE','19722',jdecode('Mary+Felton'),jdecode(''),'/8273/19722.html','true',[],'',''],
		['PAGE','42712',jdecode('JAVA'),jdecode(''),'/8273/42712.html','true',[],'',''],
		['PAGE','13885',jdecode('James+LoParo'),jdecode(''),'/8273/13885.html','true',[],'',''],
		['PAGE','44412',jdecode('AJ+Nadel'),jdecode(''),'/8273/44412.html','true',[],'',''],
		['PAGE','13822',jdecode('Elisa+Pritzker'),jdecode(''),'/8273/13822.html','true',[],'',''],
		['PAGE','19743',jdecode('Peter+Tripp'),jdecode(''),'/8273/19743.html','true',[],'','']
	],'',''],
	['PAGE','42812',jdecode('Current+Exhibition'),jdecode(''),'/42812/index.html','true',[ 
		['PAGE','44612',jdecode('About+the+artist'),jdecode(''),'/42812/44612.html','true',[],'','']
	],'',''],
	['PAGE','25101',jdecode('Press+Release'),jdecode(''),'/25101.html','true',[],'',''],
	['PAGE','8336',jdecode('The+Easels+Project'),jdecode(''),'/8336.html','true',[],'',''],
	['PAGE','8357',jdecode('Exhibition+Openings%2FEvents'),jdecode(''),'/8357.html','true',[],'',''],
	['PAGE','19764',jdecode('The+Affordables'),jdecode(''),'/19764.html','true',[],'',''],
	['PAGE','8315',jdecode('Previous+Exhibitions'),jdecode(''),'/8315.html','true',[],'',''],
	['PAGE','24101',jdecode('Our+Blog'),jdecode(''),'/24101.html','true',[],'',''],
	['PAGE','8378',jdecode('Press'),jdecode(''),'/8378.html','true',[],'',''],
	['PAGE','8399',jdecode('Gallery+News'),jdecode(''),'/8399.html','true',[],'',''],
	['PAGE','8420',jdecode('Contact'),jdecode(''),'/8420.html','true',[],'',''],
	['PAGE','31612',jdecode('Links'),jdecode(''),'/31612.html','true',[],'','']];
var siteelementCount=28;
theSitetree.topTemplateName='Alpha';
theSitetree.paletteFamily='5351C2';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10461';
theSitetree.graphicsetId='10894';
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: 			'Alpha',
				paletteFamily: 	'5351C2',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10461',
				graphicsetId: 	'10894',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'5351C2',
				e_color: 		'5351C2',
				f_color: 		'5351C2',
				hasCustomLogo: 	'true',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8201',
internalId:  '',
customField: '20100304-103533'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8252',
internalId:  '',
customField: '20100213-213308'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8273',
internalId:  '',
customField: '20100221-075342'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8294',
internalId:  '',
customField: '20100225-180234'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8315',
internalId:  '',
customField: '20091227-100621'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8336',
internalId:  '',
customField: '20100225-184220'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8357',
internalId:  '',
customField: '20100221-071855'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8378',
internalId:  '',
customField: '20091004-152305'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8399',
internalId:  '',
customField: '20100304-095838'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '8420',
internalId:  '',
customField: '20091127-090448'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13801',
internalId:  '',
customField: '20100225-180401'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13822',
internalId:  '',
customField: '20091010-204639'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '42712',
internalId:  '',
customField: '20100221-072923'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '44412',
internalId:  '',
customField: '20100225-181507'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '13885',
internalId:  '',
customField: '20091010-204639'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15501',
internalId:  '',
customField: '20091013-161649'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '18501',
internalId:  '',
customField: '20091221-194115'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19764',
internalId:  '',
customField: '20100225-173217'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19701',
internalId:  '',
customField: '20091104-144039'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19722',
internalId:  '',
customField: '20091104-144039'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '19743',
internalId:  '',
customField: '20091104-144039'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '24101',
internalId:  '',
customField: '20091127-090800'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '25101',
internalId:  '',
customField: '20100302-160735'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31612',
internalId:  '',
customField: '20091228-191612'
};
webappMappings['7060']=webappMappings['7060-7bd4ec027be1a7306c36d546eeedeb23']={
webappId:    '7060',
documentId:  '8294',
internalId:  '7bd4ec027be1a7306c36d546eeedeb23',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '48812',
internalId:  '',
customField: '20100304-100038'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '42812',
internalId:  '',
customField: '20100304-104909'
};
webappMappings['7060']=webappMappings['7060-4a8252f99d10352e58ee3a8ad3b6ca85']={
webappId:    '7060',
documentId:  '42812',
internalId:  '4a8252f99d10352e58ee3a8ad3b6ca85',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '44612',
internalId:  '',
customField: '20100302-112114'
};
webappMappings['7060']=webappMappings['7060-388b9681cc1ad1317c8d8c14cb521009']={
webappId:    '7060',
documentId:  '13801',
internalId:  '388b9681cc1ad1317c8d8c14cb521009',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '48833',
internalId:  '',
customField: '20100304-100038'
};
var canonHostname = 'wscwrk01.ehost-services.com';
var accountId     = 'AEN330INFJP6';
var companyName   = 'Franklin+54+Gallery+%2B+Projects';
var htmlTitle	  = '';
var metaKeywords  = '';
var metaContents  = '';
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();
};
