/* [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','5401',jdecode('Home'),jdecode(''), jdecode('%2F5401.html'), 'true',[],'',''],
	['PAGE','5722',jdecode('The+Principals'),jdecode(''), jdecode('%2F5722.html'), 'true',[],'',''],
	['PAGE','9433',jdecode('Hospitality+Projects'),jdecode(''), jdecode('%2F9433.html'), 'true',[],'',''],
	['PAGE','9454',jdecode('Hospitality+Portfolio+1'),jdecode(''), jdecode('%2F9454.html'), 'true',[],'',''],
	['PAGE','9475',jdecode('Hospitality+Portfolio+2'),jdecode(''), jdecode('%2F9475.html'), 'true',[],'',''],
	['PAGE','9496',jdecode('Hospitality+Portfolio+3'),jdecode(''), jdecode('%2F9496.html'), 'true',[],'',''],
	['PAGE','31334',jdecode('Hospitality+Portfolio+4'),jdecode(''), jdecode('%2F31334.html'), 'true',[],'',''],
	['PAGE','36634',jdecode('Hospitality+Portfolio+5'),jdecode(''), jdecode('%2F36634.html'), 'true',[],'',''],
	['PAGE','38534',jdecode('Hospitality+Portfolio+6'),jdecode(''), jdecode('%2F38534.html'), 'true',[],'',''],
	['PAGE','14412',jdecode('Corporate+Projects'),jdecode(''), jdecode('%2F14412.html'), 'true',[],'',''],
	['PAGE','14433',jdecode('Corporate+Portfolio+1'),jdecode(''), jdecode('%2F14433.html'), 'true',[],'',''],
	['PAGE','14454',jdecode('Corporate+Portfolio+2'),jdecode(''), jdecode('%2F14454.html'), 'true',[],'',''],
	['PAGE','5743',jdecode('Residential++Portfolio+1'),jdecode(''), jdecode('%2F5743.html'), 'true',[],'',''],
	['PAGE','9412',jdecode('Residential++Portfolio+2'),jdecode(''), jdecode('%2F9412.html'), 'true',[],'',''],
	['PAGE','15812',jdecode('Furniture+Design+Gallery'),jdecode(''), jdecode('%2F15812.html'), 'true',[],'',''],
	['PAGE','15833',jdecode('Furniture+Design+Gallery'),jdecode(''), jdecode('%2F15833.html'), 'true',[],'',''],
	['PAGE','15854',jdecode('Contact+Us'),jdecode(''), jdecode('%2F15854.html'), 'true',[],'','']];
var siteelementCount=17;
theSitetree.topTemplateName='Stars';
theSitetree.paletteFamily='3C5284';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10466';
theSitetree.graphicsetId='10913';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='3C5284';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'wl_enom',
  product: 'WSCENOSSSLYTC21T'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Stars',
				paletteFamily: 	'3C5284',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10466',
				graphicsetId: 	'10913',
				contentColor: 	'FFFFFF',
				contentBGColor: '3C5284',
				a_color: 		'3C5284',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'false',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5401',
internalId:  '',
customField: '20110601-082033'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14412',
internalId:  '',
customField: '20090203-095029'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9433',
internalId:  '',
customField: '20100807-090316'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9454',
internalId:  '',
customField: '20110625-071144'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14433',
internalId:  '',
customField: '20110602-075747'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5722',
internalId:  '',
customField: '20110625-064713'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '5743',
internalId:  '',
customField: '20110602-080500'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9496',
internalId:  '',
customField: '20110602-074818'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9475',
internalId:  '',
customField: '20110602-081158'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9412',
internalId:  '',
customField: '20110625-070335'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14454',
internalId:  '',
customField: '20110620-121131'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15812',
internalId:  '',
customField: '20100807-093610'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15833',
internalId:  '',
customField: '20110625-065915'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15854',
internalId:  '',
customField: '20110620-121915'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '31334',
internalId:  '',
customField: '20110602-075524'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '36634',
internalId:  '',
customField: '20110620-120050'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '38534',
internalId:  '',
customField: '20110620-121629'
};
var webAppHostname = 'wsc.ehost-services.com:80';
var canonHostname = 'wscwrk01.ehost-services.com';
var accountId     = 'AEN010IN29TP';
var companyName   = 'YOU+AND+I+DESIGN+INC.';
var htmlTitle	  = 'You+and+I+Design+Inc.';
var metaKeywords  = 'Interior+Architcture%2C+Furniture+Designers%2C+Visionares%2C+Space+Planners%2C++Design+Consultantants%2C+Specifiers%2C+Licensed%2C+Insured%2C+Bonded%2C+Resposible%2C+Local%2C+Professional%2C+hospitalityinteriordesign.com%2C+You+and+I+design%2C+u+and+i+design%2C+Boutique+Hotel+Design+%2C+Resorts%2C+Restaurants%2C++Spas%2C+Colorists';
var metaContents  = 'You+and+I+design%2C+Inc.+is+a+professional+hospitality+interior+design+firm+located+in+Fort+Lauderdale%2C+Florida+with+over+30+years+experience.+Hospitality+interior+design.com+is+an+international+interior+design+firm+specializing+in+customized+personalized+design+including+Boutique+Hotel+Design+%2C+Resorts%2C+Restaurants%2C++and+Spas.';
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();
};

