/* [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','701',jdecode('Home'),jdecode(''), jdecode('%2F701.html'), 'true',[],'',''],
	['PAGE','84112',jdecode('Music+Lessons+'),jdecode(''), jdecode('%2F84112.html'), 'true',[],'',''],
	['PAGE','124812',jdecode('Lil%26%23x27%3B+Jammers+'),jdecode(''), jdecode('%2F124812.html'), 'true',[],'',''],
	['PAGE','124512',jdecode('GLEE+Club'),jdecode(''), jdecode('%2F124512.html'), 'true',[],'',''],
	['PAGE','187134',jdecode('BAND+Class'),jdecode(''), jdecode('%2F187134.html'), 'true',[],'',''],
	['PAGE','55612',jdecode('ROCK+CAMP+'),jdecode(''), jdecode('%2F55612.html'), 'true',[],'',''],
	['PAGE','84133',jdecode('JamSpots'),jdecode(''), jdecode('%2F84133.html'), 'true',[],'',''],
	['PAGE','64712',jdecode('News+%26+Events'),jdecode(''), jdecode('%2F64712.html'), 'true',[],'',''],
	['PAGE','752',jdecode('About+us'),jdecode(''), jdecode('%2F752.html'), 'true',[],'',''],
	['PAGE','773',jdecode('Our+Teachers'),jdecode(''), jdecode('%2F773%2Findex.html'), 'true',[ 
		['PAGE','35301',jdecode('Dan'),jdecode(''), jdecode('%2F773%2F35301.html'), 'true',[],'',''],
		['PAGE','168255',jdecode('Dustin'),jdecode(''), jdecode('%2F773%2F168255.html'), 'true',[],'',''],
		['PAGE','61212',jdecode('Fiona'),jdecode(''), jdecode('%2F773%2F61212.html'), 'true',[],'',''],
		['PAGE','168234',jdecode('Joanna'),jdecode(''), jdecode('%2F773%2F168234.html'), 'true',[],'',''],
		['PAGE','35343',jdecode('John'),jdecode(''), jdecode('%2F773%2F35343.html'), 'true',[],'',''],
		['PAGE','168297',jdecode('John+T.'),jdecode(''), jdecode('%2F773%2F168297.html'), 'true',[],'',''],
		['PAGE','168276',jdecode('Joni+N.'),jdecode(''), jdecode('%2F773%2F168276.html'), 'true',[],'',''],
		['PAGE','35364',jdecode('Robert'),jdecode(''), jdecode('%2F773%2F35364.html'), 'true',[],'',''],
		['PAGE','168734',jdecode('Robert+K.'),jdecode(''), jdecode('%2F773%2F168734.html'), 'true',[],'',''],
		['PAGE','127923',jdecode('Shannon'),jdecode(''), jdecode('%2F773%2F127923.html'), 'true',[],'',''],
		['PAGE','134144',jdecode('Spencer'),jdecode(''), jdecode('%2F773%2F134144.html'), 'true',[],'',''],
		['PAGE','35385',jdecode('Steve+K.'),jdecode(''), jdecode('%2F773%2F35385.html'), 'true',[],'',''],
		['PAGE','150934',jdecode('Steve+T.'),jdecode(''), jdecode('%2F773%2F150934.html'), 'true',[],'',''],
		['PAGE','150955',jdecode('Steve+T..'),jdecode(''), jdecode('%2F773%2F150955.html'), 'true',[],'',''],
		['PAGE','132023',jdecode('Szabolcs'),jdecode(''), jdecode('%2F773%2F132023.html'), 'true',[],'',''],
		['PAGE','150834',jdecode('Thomas'),jdecode(''), jdecode('%2F773%2F150834.html'), 'true',[],'',''],
		['PAGE','58612',jdecode('Tyler'),jdecode(''), jdecode('%2F773%2F58612.html'), 'true',[],'',''],
		['PAGE','92212',jdecode('Valerie'),jdecode(''), jdecode('%2F773%2F92212.html'), 'true',[],'','']
	],'',''],
	['PAGE','147934',jdecode('JAM+AUDIO+'),jdecode(''), jdecode('%2F147934.html'), 'true',[],'',''],
	['PAGE','48012',jdecode('RecordingSchool'),jdecode(''), jdecode('%2F48012.html'), 'true',[],'',''],
	['PAGE','22822',jdecode('Products'),jdecode(''), jdecode('%2F22822.html'), 'false',[],'',''],
	['PAGE','97612',jdecode('JamStore'),jdecode(''), jdecode('%2F97612.html'), 'true',[],'',''],
	['PAGE','102112',jdecode('Past+Events'),jdecode(''), jdecode('%2F102112.html'), 'false',[],'',''],
	['PAGE','22801',jdecode('Offers'),jdecode(''), jdecode('%2F22801.html'), 'false',[],'',''],
	['PAGE','22906',jdecode('Jobs'),jdecode(''), jdecode('%2F22906.html'), 'true',[],'',''],
	['PAGE','22927',jdecode('Contact+Info'),jdecode(''), jdecode('%2F22927.html'), 'true',[],'',''],
	['PAGE','95912',jdecode('Privacy+Policy'),jdecode(''), jdecode('%2F95912.html'), 'true',[],'','']];
var siteelementCount=37;
theSitetree.topTemplateName='Steel';
theSitetree.paletteFamily='CA0E0E';
theSitetree.keyvisualId='-1';
theSitetree.keyvisualName='keyv.jpg';
theSitetree.fontsetId='10808';
theSitetree.graphicsetId='11242';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='4E4E4E';
var localeDef={
  language: 'en',
  country: 'US'
};
var prodDef={
  wl_name: 'enom',
  product: 'WSCENOSSSLYTC210'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Steel',
				paletteFamily: 	'CA0E0E',
				keyvisualId: 	'-1',
				keyvisualName: 	'keyv.jpg',
				fontsetId: 		'10808',
				graphicsetId: 	'11242',
				contentColor: 	'FFFFFF',
				contentBGColor: '4E4E4E',
				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:     'true'
			  };
var webappMappings = {};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '701',
internalId:  '1006',
customField: '1006'
};
webappMappings['7008']=webappMappings['7008-3837']={
webappId:    '7008',
documentId:  '22927',
internalId:  '3837',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '701',
internalId:  '',
customField: '20111221-082015'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '150934',
internalId:  '',
customField: '20110219-120627'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '150955',
internalId:  '',
customField: '20110219-120627'
};
webappMappings['1501']=webappMappings['1501-9720173']={
webappId:    '1501',
documentId:  '701',
internalId:  '9720173',
customField: '1501'
};
webappMappings['7060']=webappMappings['7060-12f6e5f38c4682a5289db7dc98ce019f']={
webappId:    '7060',
documentId:  '102112',
internalId:  '12f6e5f38c4682a5289db7dc98ce019f',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '124812',
internalId:  '',
customField: '20111214-093044'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '124512',
internalId:  '',
customField: '20111214-093100'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '168234',
internalId:  '',
customField: '20111203-081311'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '84112',
internalId:  '',
customField: '20111214-092804'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '187134',
internalId:  '',
customField: '20111214-093117'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '84133',
internalId:  '',
customField: '20111214-093323'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '132023',
internalId:  '',
customField: '20091209-092710'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '55612',
internalId:  '',
customField: '20111214-093221'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '64712',
internalId:  '',
customField: '20111214-093553'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '752',
internalId:  '',
customField: '20111214-093728'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '773',
internalId:  '',
customField: '20111221-080902'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '35301',
internalId:  '',
customField: '20091209-091422'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '168255',
internalId:  '',
customField: '20111203-081311'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '61212',
internalId:  '',
customField: '20080620-163529'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '35343',
internalId:  '',
customField: '20080620-163613'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '127923',
internalId:  '',
customField: '20090909-070236'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '134144',
internalId:  '',
customField: '20100219-192441'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '168734',
internalId:  '',
customField: '20111203-083043'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '35364',
internalId:  '',
customField: '20100730-092446'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '35385',
internalId:  '',
customField: '20080620-163751'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '58612',
internalId:  '',
customField: '20100727-090010'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '92212',
internalId:  '',
customField: '20080902-191737'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '48012',
internalId:  '',
customField: '20111214-094227'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22822',
internalId:  '',
customField: '20100709-094540'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '97612',
internalId:  '',
customField: '20111214-094514'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '102112',
internalId:  '',
customField: '20090913-082934'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22801',
internalId:  '',
customField: '20110219-115244'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22906',
internalId:  '',
customField: '20100714-145431'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '22927',
internalId:  '',
customField: '20111214-094556'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '168297',
internalId:  '',
customField: '20111203-081311'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '147934',
internalId:  '',
customField: '20111214-093832'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '150834',
internalId:  '',
customField: '20110219-121017'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '95912',
internalId:  '',
customField: '20090328-180912'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '168276',
internalId:  '',
customField: '20111203-081311'
};
var webAppHostname = 'wsc.ehost-services.com:80';
var canonHostname = 'wscwrk01.ehost-services.com';
var accountId     = 'AEN010IN3F7Q';
var companyName   = 'JamSchool+-+Music+and+Audio';
var htmlTitle	  = 'JAM+School+-+JamSchool+-+Music+Lessons%2C+Rehearsal+Studio%2C+Jam+Spot%2C+Guelph';
var metaKeywords  = 'Music+School%2C+Instruction%2C+Retail+supply%2C+Musical+Instruments%2C+Jam%2C+JAM%2C+JamSchool%2C+Ontario%2C+Guelph%2C+Canada%2C+guitar%2C+drums%2C+piano%2C+keyboard%2C+vocal%2C+singing%2C+rock%2C+rockstar%2C+kids%2C+camp%2C+summer+camp%2C+Jam+Spot%2C+jam+spots%2C+rehearsal+studio%2C+music+studio%2C+music+lessons%2C+music+lesson%2C+guitar+lesson%2C+drum+lessons%2C+vocal+lessons%2C+piano+lessons%2C+music+lessons+guelph%2C+peavey%2C+yamaha%2C';
var metaContents  = 'Music+School%2C+Instruction%2C+Retail+supply%2C+Musical+Instruments%2C+Jam%2C+JAM%2C+JamSchool%2C+Ontario%2C+Guelph%2C+Canada%2C+guitar%2C+drums%2C+piano%2C+keyboard%2C+vocal%2C+singing%2C+rock%2C+rockstar%2C+kids%2C+camp%2C+summer+camp%2C+Jam+Spot%2C+jam+spots%2C+rehearsal+studio%2C+music+studio%2C+music+lessons%2C+music+lesson%2C+guitar+lesson%2C+drum+lessons%2C+vocal+lessons%2C+piano+lessons%2C+music+lessons+guelph%2C+peavey%2C+yamaha%2C';
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();
};

