/* [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','201',jdecode('Our+Journey+to+You'),jdecode(''), jdecode('%2F201.html'), 'true',[],'',''],
	['PAGE','7501',jdecode('About+Me'),jdecode(''), jdecode('%2F7501.html'), 'true',[],'',''],
	['PAGE','7522',jdecode('Created+Just+For+You'),jdecode(''), jdecode('%2F7522.html'), 'true',[],'',''],
	['PAGE','7543',jdecode('Fast+Turnaround%21'),jdecode(''), jdecode('%2F7543.html'), 'true',[],'',''],
	['PAGE','7564',jdecode('Adoption+Portfolios'),jdecode(''), jdecode('%2F7564.html'), 'true',[],'',''],
	['PAGE','7606',jdecode('Pricing'),jdecode(''), jdecode('%2F7606.html'), 'true',[],'',''],
	['PAGE','11933',jdecode('Where+to+begin'),jdecode(''), jdecode('%2F11933.html'), 'true',[],'',''],
	['PAGE','11912',jdecode('Contact+Me...'),jdecode(''), jdecode('%2F11912.html'), 'true',[],'',''],
	['PAGE','29512',jdecode('waiting+families'),jdecode(''), jdecode('%2F29512.html'), 'false',[],'','']];
var siteelementCount=9;
theSitetree.topTemplateName='Porthole';
theSitetree.paletteFamily='A68025';
theSitetree.keyvisualId='6704';
theSitetree.keyvisualName='kv_6704.jpg';
theSitetree.fontsetId='11201';
theSitetree.graphicsetId='12016';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='FBF7E7';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'endurance',
  product: 'WSCSYSSSSLY0XRNC'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Porthole',
				paletteFamily: 	'A68025',
				keyvisualId: 	'6704',
				keyvisualName: 	'kv_6704.jpg',
				fontsetId: 		'11201',
				graphicsetId: 	'12016',
				contentColor: 	'000000',
				contentBGColor: 'FBF7E7',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'000000',
				e_color: 		'000000',
				f_color: 		'000000',
				hasCustomLogo: 	'false',
				contentFontFace:'Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '201',
internalId:  '',
customField: '20120201-135538'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '201',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7564',
internalId:  '',
customField: '20091102-134417'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7501',
internalId:  '',
customField: '20100206-075715'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7522',
internalId:  '',
customField: '20110309-163141'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7543',
internalId:  '',
customField: '20091102-134220'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29512',
internalId:  '',
customField: '20120115-130105'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '7606',
internalId:  '',
customField: '20111105-124750'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '11912',
internalId:  '',
customField: '20120116-213413'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '11933',
internalId:  '',
customField: '20110309-161031'
};
var webAppHostname = 'cgiwsc.enhancedsitebuilder.com:80';
var canonHostname = 'cmworker02.yourhostingaccount.com';
var accountId     = 'AENDU0IN2KHL';
var companyName   = 'Our+Journey+to+You';
var htmlTitle	  = 'Our+Journey+To+You%7ECustom+Adoption+Profiles%2C+Adoption+Portfolios+%26+Birthmother+Letters';
var metaKeywords  = 'Birthmother+letters%2C+Birthparent+Letters%2C+Adoption+Portfolios%2C+Adoption+Profiles%2C+Adoptive+Parents%2C+Birthmother+letter+help%2C+Birthparent+Letter+help%2C+Adoption+Portfolio+help%2C+Adoption+Profile+help%2C+Birthmother+letter+creation%2C+Birthparent+Letter+creation%2C+Adoption+Portfolio+creation%2C+Adoption+Profile+creation%2C+How+to+write+a+Birthmother+Letter%2C+Writing+a+Birthmother+letter%2C+trying+to+adopt%2C+Adoption+Services%2C+Adoption+Resources%2C+Life+Books%2C+Adoption+Gifts%2C+E-mail+Adoption+Announcements%2CBirthmother+letter+services%2C+Birthparent+Letter+Services%2C+Adoption+Portfolio+services%2C+Adoption+Profile+services%2C+Writing+a+Dear+Birthmother+Letter%2C+Letter+to+the+Birthmother%2C+Writing+an+Adoption+Profile%2C+Birthmother+Letter+samples%2C+Birthparent+letter+samples%2C+adoption+letter+samples%2C+adoption+profile+samples%2C+adoption+portfolio+samples%2C+adoption+resources%2C+adoption+portfolio+resources%2C+adoption+profile+resources%2C+Birthmother+Letter+writing+resources%2C+great+birthmother+letters%2C+our+journey+to+you%2C+starting+an+adoption+profile%2C+starting+an+adoption+portfolio%2C+adoption+profiles+that+work%2C+great+adoption+profiles%2C+letter+to+a+birthmother%2C+Birthmother+letter+design%2C+Adoption+portfolio+design%2C+adoption+profile+design%2C+adoption+picture+profiles%2C+adoption+picture+portfolios%2C+adoption+portfolio%2C+Birthmother+letter+writing%2C+how+to+start+an+adoption+profile%2Chow+to+create+an+adoption+profile%2Chow+to+start+an+adoption+portfolio%2C+how+to+create+an+adoption+portfolio%2Chow+to+start+a+Dear+Birthmother+Letter%2C+how+to+create+a+Dear+Birthmother+Letter%2C+how+to+write+a+Dear+Birthmother+Letter%2Cmarketing+to+a+birthmother%2C+thank+you+letter+to+a+birthmother%2C+birthparents+letters%2C+birthparent+profiles%2C+adoptive+couple+profiles%2C+adoptive+family+profiles%2C+adoption+help%2C+birthmother+letter+help%2C+adoption+profile+help%2C+adoption+portfolio+help%2C+best+adoption+letter%2C+we+are+adopting%2C+what+to+do+when+you+are+adopting%2C+how+to+make+the+best+birthmother+letter%2C+how+to+make+the+best+adoption+letter%2C+adoption+profile+layout%2C+adoption+portfolio+programs%2C+adoption+letter+programs%2C+adoption+letter+help%2C+best+layout+for+adoption+profiles%2C+family+profiles%2C+adoption+profile+samples%2C+adoption+profile+examples%2C+adoption+portfolio+examples%2C+adoption+portfolio+samples%2C+birthparent+letter+examples%2C+birthparent+letter+samples%2C+birthmother+letter+examples%2C+birthmother+letter+samples%2C+best+adoption+profile%2C+best+adoption+portfolio%2C+best+birthparent+letter%2C+adoption+portfolio+programs%2C+adoption+profile+programs%2C+birthmother+letter+programs%2C+writing+a+letter+to+a+birthmother%2C+writing+a+letter+to+a+birthparent%2C+how+to+get+birthmothers+to+read+my+letter%2C+writing+a+birthmother+letter+that+gets+picked%2C+adoption+portfolios+that+get+picked%2C+adoption+profiles+that+get+picked%2C+our+chosen+child%2C+our+journey+to+you+adoption%2C+adoption+profiles+that+work%2C+adoption+letters+that+work%2C+adoption+profile+design%2C+adoption+portfolio+design%2C+dear+birthmother+letter+design%2C+ideas+for+adoption+profiles%2C+ideas+for+adoption+portfolios%2C+adoption+profile+creation%2C+profiles+for+adoption%2C+family+profiles%2C+writing+an+adoption+profile%2C+chosen+child+through+adoption+profiles%2C+chosen+child+through+adoption+portfolio%2C+forever+families+through+adoption+profiles%2C+forever+family+through+adoption+portfolios%2C+creative+adoption+profile%2C+creative+adoption+portfolios%2C+adoption+profile+that+gets+chosen%2C+adoption+portfolio+that+gets+chosen%2C+birthparent+letter%2C+family+profile%2C+family+book%2C+letter+to+birthmother%2C+what+to+include+in+an+adoption+profile%2C+text+for+adoption+profile%2C+best+programs+for+creating+an+adoption+profile%2C+best+programs+for+creating+an+adoption+portfolio%2C+how+to+get+a+birthmother%27s+attention%2C+how+to+be+chosen+by+a+birthmother%2C+what+to+write+in+an+adoption+profile%2C+best+adoption+profile%2C+sample+of+an+adoption+profile%2C+sample+of+an+adoption+portfolio%2C+pictures+of+an+adoption+profile%2C+help+with+an+adoption+profile%2C+adoptive+parents%2C+trying+to+adopt%2C+successful+adoption+profiles%2C+successful+adoption+portfolios%2C+what+to+have+in+an+adoption+portfolio%2C+how+to+put+together+a+portfolio+for+birth+mothers%2C+adoption+portfolio+for+second+adoption%2C+adoption+profile+for+second+adoption%2C+waiting+families%2C+adoptive+couples%2C+birthmother+services%2C+birthparent+services%2C+families+who+want+to+adopt%2C+hopeful+adoptive+families%2C+couples+who+dream+of+a+child%2C+couples+who+want+to+adopt+a+child%2C+adoption+profile+design+services%2C+adoption+profile+letter%2C+adoptive+parent+profiles%2C+adoptive+parent+portfolios%2C+sample+adoption+profile+book%2C+adoption+profile+ideas%2C+adoption+portfolio+ideas%2C+adoption+portfolio+design+services%2C+adoption%2C+adoption+profile+help%2C+adoption+portfolio+help%2C+adoption+profile+design%2C+adoption+portfolio+design%2C+adoption+portfolio+layout%2C+adoption+profile+layout%2C+adoption+portfolio+letter%2C+birthmother+letter+for+second+adoption%2C+adoption+profile+tips%2C+adoption+portfolio+tips%2C+letters+to+a+birthmother';
var metaContents  = 'Custom+Adoption+Portfolio+creation%2C+Adoption+Profile+%26++Birthmother+Letter+Creation+and+Design+Services...Let+me+help+you+create+an+Adoption+Portfolio%2C+Adoption+Profile+or+Birthmother+Letter+that+reflects+you+in+your+truest%2C+best+light.++The+first+impression...A+first+step+to+the+dream+of+a+child...Let+us+help+to+tell+your+story%21++If+you+are+worried+you+do+not+have+to+time+or+the+knack+to+create+your+own%2C+let+an+adoptee+and+mother+of+3+adopted+children+help+you%21+I+specialize+in+Adoption+Portfolio+design%2C+Adoption+Profile+design+and+the+creation+of+custom+Birthmother+Letters.';
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();
};

