/* [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 theSitetree=[ 
	['PAGE','62',jdecode('Home'),jdecode(''),'/62.html','true',[],''],
	['PAGE','33212',jdecode('Specials'),jdecode(''),'/33212.html','true',[],''],
	['PAGE','24012',jdecode('Wedding+Trends'),jdecode(''),'/24012/index.html','true',[ 
		['PAGE','29212',jdecode('Articles+and+Print'),jdecode(''),'/24012/29212.html','true',[],'']
	],''],
	['PAGE','24033',jdecode('Wedding+Traditions'),jdecode(''),'/24033.html','true',[],''],
	['PAGE','9601',jdecode('Ask+The+Expert'),jdecode(''),'/9601.html','true',[],''],
	['PAGE','83',jdecode('Gowns+%26++More'),jdecode(''),'/83/index.html','true',[ 
		['PAGE','92',jdecode('Gowns'),jdecode(''),'/83/92.html','true',[],''],
		['PAGE','12801',jdecode('Designers+We+Carry'),jdecode(''),'/83/12801.html','true',[],''],
		['PAGE','10501',jdecode('Featured+Designer'),jdecode(''),'/83/10501.html','true',[],''],
		['PAGE','10401',jdecode('Modest+Options'),jdecode(''),'/83/10401.html','true',[],''],
		['PAGE','10422',jdecode('Custom+Gowns'),jdecode(''),'/83/10422.html','true',[],''],
		['PAGE','101',jdecode('Maids+%26+Moms'),jdecode(''),'/83/101.html','true',[],''],
		['PAGE','29512',jdecode('Out+of+Town+Attendants%3F'),jdecode(''),'/83/29512.html','true',[],''],
		['PAGE','9622',jdecode('Mens%26%23x27%3B+Apparel'),jdecode(''),'/83/9622.html','true',[],''],
		['PAGE','110',jdecode('Finishing+Touches'),jdecode(''),'/83/110.html','true',[],''],
		['PAGE','26812',jdecode('Veils'),jdecode(''),'/83/26812.html','true',[],''],
		['PAGE','10522',jdecode('Prom+%26+Cotillion'),jdecode(''),'/83/10522.html','true',[],''],
		['PAGE','10543',jdecode('Services'),jdecode(''),'/83/10543.html','true',[],''],
		['PAGE','10564',jdecode('Quincinera'),jdecode(''),'/83/10564.html','true',[],'']
	],''],
	['PAGE','128',jdecode('Contact'),jdecode(''),'/128.html','true',[],''],
	['PAGE','137',jdecode('Our+Store+'),jdecode(''),'/137.html','true',[],''],
	['PAGE','146',jdecode('Online+Shopping'),jdecode(''),'/146.html','true',[],''],
	['PAGE','9643',jdecode('Upcoming+Events'),jdecode(''),'/9643.html','true',[],''],
	['PAGE','155',jdecode('Tips+%26+Policies'),jdecode(''),'/155.html','true',[],''],
	['PAGE','9664',jdecode('Customer+Comments'),jdecode(''),'/9664.html','true',[],''],
	['PAGE','9685',jdecode('Health+and+Beauty'),jdecode(''),'/9685.html','true',[],''],
	['PAGE','9706',jdecode('Recommended+Vendors'),jdecode(''),'/9706.html','true',[],''],
	['PAGE','10701',jdecode('Site+Photography'),jdecode(''),'/10701.html','true',[],''],
	['PAGE','9748',jdecode('Jobs'),jdecode(''),'/9748.html','true',[],''],
	['PAGE','28512',jdecode('GBL+vs+the+Others'),jdecode(''),'/28512.html','true',[],''],
	['PAGE','28712',jdecode('Support+Business'),jdecode(''),'/28712.html','true',[],'']];
var siteelementCount=32;
theSitetree.topTemplateName='Ornaments';
theSitetree.paletteFamily='3E8832';
theSitetree.keyvisualId='3899';
theSitetree.keyvisualName='kv_3899.jpg';
theSitetree.fontsetId='10506';
theSitetree.graphicsetId='11077';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FFFFFF';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				name: 			'Ornaments',
				paletteFamily: 	'3E8832',
				keyvisualId: 	'3899',
				keyvisualName: 	'kv_3899.jpg',
				fontsetId: 		'10506',
				graphicsetId: 	'11077',
				contentColor: 	'000000',
				contentBGColor: 'FFFFFF',
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'887248',
				e_color: 		'887248',
				f_color: 		'887248',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['7050']=webappMappings['7050-86']={
webappId:    '7050',
documentId:  '9664',
internalId:  '86',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '62',
internalId:  '',
customField: '20100102-153019'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '83',
internalId:  '',
customField: '20100122-224529'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '92',
internalId:  '',
customField: '20091226-202448'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10501',
internalId:  '',
customField: '20091213-205446'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10401',
internalId:  '',
customField: '20091227-233418'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '101',
internalId:  '',
customField: '20091227-202343'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9622',
internalId:  '',
customField: '20100122-225015'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '62',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9601',
internalId:  '',
customField: '20091229-222624'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '12801',
internalId:  '',
customField: '20091227-233304'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9664',
internalId:  '',
customField: '20091227-233656'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10422',
internalId:  '',
customField: '20091227-200628'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10522',
internalId:  '',
customField: '20091226-200220'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '128',
internalId:  '',
customField: '20100110-231223'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '110',
internalId:  '',
customField: '20100110-225828'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10543',
internalId:  '',
customField: '20091227-222814'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10564',
internalId:  '',
customField: '20100110-230423'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '137',
internalId:  '',
customField: '20100110-220730'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '146',
internalId:  '',
customField: '20061109-085126'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9643',
internalId:  '',
customField: '20100110-223000'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '155',
internalId:  '',
customField: '20100125-162553'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9685',
internalId:  '',
customField: '20091226-222244'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9706',
internalId:  '',
customField: '20100122-224507'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '10701',
internalId:  '',
customField: '20091226-220327'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9748',
internalId:  '',
customField: '20091228-145256'
};
webappMappings['7060']=webappMappings['7060-68c291eced72532c72490e43cacd2edb']={
webappId:    '7060',
documentId:  '24012',
internalId:  '68c291eced72532c72490e43cacd2edb',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '24033',
internalId:  '',
customField: '20091227-213728'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '24012',
internalId:  '',
customField: '20091230-141909'
};
webappMappings['1501']=webappMappings['1501-1070019']={
webappId:    '1501',
documentId:  '62',
internalId:  '1070019',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26812',
internalId:  '',
customField: '20091228-173522'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28512',
internalId:  '',
customField: '20100110-222746'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '28712',
internalId:  '',
customField: '20100110-182116'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29212',
internalId:  '',
customField: '20100110-182106'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29512',
internalId:  '',
customField: '20100122-223146'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '33212',
internalId:  '',
customField: '20100125-172649'
};
var canonHostname = 'cm4all01.west-datacenter.net';
var accountId     = 'AWH010IN2K8W';
var companyName   = 'The+Gallery+by+Lynette';
var htmlTitle	  = 'Custom+Modest+and+Contemporary+Designer+Wedding+Gowns+on+a+Budget';
var metaKeywords  = 'Wedding+Gown%2CCustom+Wedding+dress%2C+gown%2C+Crystal+couture%2C+Utah%2C+Mormon%2C+LDS%2C+Latterday%2C+Bride%2C+Groom';
var metaContents  = 'Wow+wedding+gowns+in+modest+and+contemporary+styles.++Custom+styles+and+un+rivaled+alteration+services.';
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();
};
