/* [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','1699',jdecode('History+%26+Archives'),jdecode(''), jdecode('%2F1699.html'), 'false',[],'',''],
	['PAGE','176101',jdecode('Visit+in+Eiselfing'),jdecode(''), jdecode('%2F176101.html'), 'false',[],'',''],
	['PAGE','184403',jdecode('PASCH'),jdecode(''), jdecode('%2F184403.html'), 'false',[],'',''],
	['PAGE','45901',jdecode('*ACCOLADES*'),jdecode(''), jdecode('%2F45901.html'), 'false',[],'',''],
	['PAGE','189196',jdecode('Home'),jdecode(''), jdecode('%2F189196.html'), 'true',[],'',''],
	['PAGE','189250',jdecode('School+News'),jdecode(''), jdecode('%2F189250%2Findex.html'), 'true',[ 
		['PAGE','192949',jdecode('Adult+Classes'),jdecode(''), jdecode('%2F189250%2F192949.html'), 'true',[],'',''],
		['PAGE','192070',jdecode('Dress+Code'),jdecode(''), jdecode('%2F189250%2F192070.html'), 'true',[],'',''],
		['PAGE','192097',jdecode('Drop+Off%2FPick+Up'),jdecode(''), jdecode('%2F189250%2F192097.html'), 'true',[],'',''],
		['PAGE','191993',jdecode('Nutrition'),jdecode(''), jdecode('%2F189250%2F191993.html'), 'true',[],'',''],
		['PAGE','192536',jdecode('Optional+Intensives'),jdecode(''), jdecode('%2F189250%2F192536.html'), 'false',[],'',''],
		['PAGE','192376',jdecode('Registration'),jdecode(''), jdecode('%2F189250%2F192376.html'), 'true',[],'',''],
		['PAGE','223765',jdecode('Samstagsschule'),jdecode(''), jdecode('%2F189250%2F223765.html'), 'true',[],'',''],
		['PAGE','192061',jdecode('School+Clubs'),jdecode(''), jdecode('%2F189250%2F192061.html'), 'true',[],'',''],
		['PAGE','191181',jdecode('Summer+Camp'),jdecode(''), jdecode('%2F189250%2F191181.html'), 'false',[],'','']
	],'',''],
	['PAGE','189377',jdecode('Upcoming+Events'),jdecode(''), jdecode('%2F189377.html'), 'true',[],'',''],
	['PAGE','191779',jdecode('Help+Needed'),jdecode(''), jdecode('%2F191779.html'), 'true',[],'',''],
	['PAGE','189205',jdecode('About+Rilke+Schule'),jdecode(''), jdecode('%2F189205%2Findex.html'), 'true',[ 
		['PAGE','189296',jdecode('Admission'),jdecode(''), jdecode('%2F189205%2F189296.html'), 'true',[],'',''],
		['PAGE','190604',jdecode('Cultural+Events'),jdecode(''), jdecode('%2F189205%2F190604.html'), 'true',[],'',''],
		['PAGE','189350',jdecode('Curriculum'),jdecode(''), jdecode('%2F189205%2F189350.html'), 'true',[],'',''],
		['PAGE','189223',jdecode('Goals'),jdecode(''), jdecode('%2F189205%2F189223.html'), 'true',[],'',''],
		['PAGE','189395',jdecode('History'),jdecode(''), jdecode('%2F189205%2F189395.html'), 'true',[],'',''],
		['PAGE','192079',jdecode('Intern+Program'),jdecode(''), jdecode('%2F189205%2F192079.html'), 'true',[],'',''],
		['PAGE','189214',jdecode('Mission+and+Vision'),jdecode(''), jdecode('%2F189205%2F189214.html'), 'true',[],'',''],
		['PAGE','189305',jdecode('Policies'),jdecode(''), jdecode('%2F189205%2F189305.html'), 'true',[],'',''],
		['PAGE','30501',jdecode('School+Staff'),jdecode(''), jdecode('%2F189205%2F30501.html'), 'true',[],'',''],
		['PAGE','1615',jdecode('Treasures'),jdecode(''), jdecode('%2F189205%2F1615.html'), 'true',[],'','']
	],'',''],
	['PAGE','189232',jdecode('Prospective+Parents'),jdecode(''), jdecode('%2F189232.html'), 'true',[],'',''],
	['PAGE','1720',jdecode('APC'),jdecode(''), jdecode('%2F1720.html'), 'true',[],'',''],
	['PAGE','192088',jdecode('RSV+%28PTO%29'),jdecode(''), jdecode('%2F192088.html'), 'true',[],'',''],
	['PAGE','189332',jdecode('FAQ'),jdecode(''), jdecode('%2F189332.html'), 'true',[],'',''],
	['PAGE','189268',jdecode('Contacts'),jdecode(''), jdecode('%2F189268.html'), 'true',[],'',''],
	['PAGE','189277',jdecode('Links'),jdecode(''), jdecode('%2F189277.html'), 'true',[],'','']];
var siteelementCount=34;
theSitetree.topTemplateName='Round';
theSitetree.paletteFamily='CC3333';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='439';
theSitetree.graphicsetId='495';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='e47272';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'valueweb',
  product: 'WSCSYSSSSLYTCR7V'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Round',
				paletteFamily: 	'CC3333',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'439',
				graphicsetId: 	'495',
				contentColor: 	'000000',
				contentBGColor: 'e47272',
				a_color: 		'e47272',
				b_color: 		'CC3333',
				c_color: 		'FFFFFF',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '189196',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1615',
internalId:  '',
customField: '20100908-183738'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1699',
internalId:  '',
customField: '20090418-153613'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '30501',
internalId:  '',
customField: '20120104-170228'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1720',
internalId:  '',
customField: '20120206-015420'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '176101',
internalId:  '',
customField: '20081008-204432'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '184403',
internalId:  '',
customField: '20081008-204625'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '45901',
internalId:  '',
customField: '20081008-205143'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '223765',
internalId:  '',
customField: '20110806-021144'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189196',
internalId:  '',
customField: '20120206-002425'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189205',
internalId:  '',
customField: '20120104-003501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189214',
internalId:  '',
customField: '20100202-124316'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189223',
internalId:  '',
customField: '20090408-014208'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189232',
internalId:  '',
customField: '20110923-204143'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189250',
internalId:  '',
customField: '20120206-013824'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192070',
internalId:  '',
customField: '20110805-185216'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189268',
internalId:  '',
customField: '20110722-122819'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189277',
internalId:  '',
customField: '20100524-021830'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189296',
internalId:  '',
customField: '20110806-215951'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189305',
internalId:  '',
customField: '20110814-184526'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189332',
internalId:  '',
customField: '20111024-142332'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192949',
internalId:  '',
customField: '20110810-010426'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189350',
internalId:  '',
customField: '20110806-220409'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '191993',
internalId:  '',
customField: '20110805-192836'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189377',
internalId:  '',
customField: '20120125-142309'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '191181',
internalId:  '',
customField: '20110723-143701'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '189395',
internalId:  '',
customField: '20110806-221122'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '191779',
internalId:  '',
customField: '20120104-003324'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '190604',
internalId:  '',
customField: '20110807-145741'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192097',
internalId:  '',
customField: '20110818-142928'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192061',
internalId:  '',
customField: '20111214-184041'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192079',
internalId:  '',
customField: '20110806-222648'
};
webappMappings['1501']=webappMappings['1501-2943997']={
webappId:    '1501',
documentId:  '189196',
internalId:  '2943997',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192088',
internalId:  '',
customField: '20120111-174715'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192376',
internalId:  '',
customField: '20111024-142011'
};
webappMappings['7008']=webappMappings['7008-4402']={
webappId:    '7008',
documentId:  '192536',
internalId:  '4402',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '192536',
internalId:  '',
customField: '20100625-222942'
};
var webAppHostname = 'cgi-wsc.chi.us.siteprotect.com:80';
var canonHostname = 'wsc-worker02.chi.us.siteprotect.com';
var accountId     = 'AHW050INXSS0';
var companyName   = 'Rilke+Schule+German+School+of+Arts+%26+Sciences';
var htmlTitle	  = 'Rilke+Schule+German+School+of+Arts++Sciences';
var metaKeywords  = 'German+++German+language++culture++immersion++immersion+school+++bilingual++charter+school++Anchorage++Alaska++elementary+school++middle+school++++admission+forms++';
var metaContents  = 'Rilke+Schule++German+school++charter+school++immersion+school+++Anchorage+++AK++Alaska+rilkeschule+++lottery+forms+++school+policies++current+events';
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();
};

