/* [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','29',jdecode('Home'),jdecode(''),'/29.html','true',[],'',''],
	['PAGE','50',jdecode('Quem+somos'),jdecode(''),'/50.html','true',[],'',''],
	['PAGE','2330',jdecode('A+Empresa'),jdecode(''),'/2330/index.html','true',[ 
		['PAGE','1173',jdecode('Servi%C3%A7os'),jdecode(''),'/2330/1173.html','true',[],'','']
	],'',''],
	['PAGE','59',jdecode('A+m%C3%BAsica+e+a+arte'),jdecode(''),'/59/index.html','true',[ 
		['PAGE','68',jdecode('M%C3%BAsicas+%3A+Composi%C3%A7%C3%B5es+'),jdecode(''),'/59/68.html','true',[],'',''],
		['PAGE','77',jdecode('M%C3%BAsicas+%3A+Interpreta%C3%A7%C3%B5es'),jdecode(''),'/59/77.html','true',[],'',''],
		['PAGE','86',jdecode('CDs+%3A'),jdecode(''),'/59/86.html','true',[],'','']
	],'',''],
	['PAGE','1093',jdecode('Novidades'),jdecode(''),'/1093.html','true',[],'',''],
	['PAGE','1137',jdecode('Not%C3%ADcias'),jdecode(''),'/1137.html','true',[],'',''],
	['PAGE','9801',jdecode('++Album+de+Fotos'),jdecode(''),'/9801.html','true',[],'',''],
	['PAGE','1146',jdecode('%C3%81lbum+de+fotos'),jdecode(''),'/1146/index.html','true',[ 
		['PAGE','1155',jdecode('+'),jdecode(''),'/1146/1155.html','true',[],'','']
	],'',''],
	['PAGE','2293',jdecode('Meus+Amigos'),jdecode(''),'/2293.html','true',[],'',''],
	['PAGE','1182',jdecode('Imprensa'),jdecode(''),'/1182.html','true',[],'',''],
	['PAGE','95',jdecode('Contato'),jdecode(''),'/95.html','true',[],'',''],
	['PAGE','2436',jdecode('Servi%C3%A7o+de+bilhetes'),jdecode(''),'/2436.html','false',[],'',''],
	['PAGE','2437',jdecode('Livro+de+visitas%2FF%C3%B3rum'),jdecode(''),'/2437.html','true',[],'','']];
var siteelementCount=18;
theSitetree.topTemplateName='Kreis';
theSitetree.paletteFamily='4D4CD2';
theSitetree.keyvisualId='588';
theSitetree.keyvisualName='computer.jpg';
theSitetree.fontsetId='127';
theSitetree.graphicsetId='140';
theSitetree.contentColor='FFFFFF';
theSitetree.contentBGColor='000000';
var localeDef={
  language: 'pt',
  country: 'BR'
};
var theTemplate={
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				name: 			'Kreis',
				paletteFamily: 	'4D4CD2',
				keyvisualId: 	'588',
				keyvisualName: 	'computer.jpg',
				fontsetId: 		'127',
				graphicsetId: 	'140',
				contentColor: 	'FFFFFF',
				contentBGColor: '000000',
				a_color: 		'4D4CD2',
				b_color: 		'7794F8',
				c_color: 		'000000',
				d_color: 		'FFFFFF',
				e_color: 		'FFFFFF',
				f_color: 		'FFFFFF',
				hasCustomLogo: 	'false',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'false'
			  };
var webappMappings = {};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '29',
internalId:  '1006',
customField: '1006'
};
webappMappings['1501']=webappMappings['1501-1396369']={
webappId:    '1501',
documentId:  '29',
internalId:  '1396369',
customField: '1501'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '29',
internalId:  '',
customField: '20100213-151652'
};
webappMappings['1002']=webappMappings['1002-2437AVEC10IN2PQM']={
webappId:    '1002',
documentId:  '2437',
internalId:  '2437AVEC10IN2PQM',
customField: 'icq=false'
};
webappMappings['7060']=webappMappings['7060-5e3a97e13a37cdd2988b3abe7e716bb1']={
webappId:    '7060',
documentId:  '9801',
internalId:  '5e3a97e13a37cdd2988b3abe7e716bb1',
customField: 'language:pt;country:BR;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2293',
internalId:  '',
customField: '20091111-220658'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '50',
internalId:  '',
customField: '20091123-104437'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2330',
internalId:  '',
customField: '20060916-003940'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1173',
internalId:  '',
customField: '20080918-091445'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '59',
internalId:  '',
customField: '20091123-104747'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '68',
internalId:  '',
customField: '20100213-150048'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '77',
internalId:  '',
customField: '20060916-004802'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '86',
internalId:  '',
customField: '20091123-105304'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1093',
internalId:  '',
customField: '20061228-220227'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1137',
internalId:  '',
customField: '20080611-222530'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '9801',
internalId:  '',
customField: '20070401-213925'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1146',
internalId:  '',
customField: '20060916-010050'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1182',
internalId:  '',
customField: '20091123-110222'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '95',
internalId:  '',
customField: '20091203-205245'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2437',
internalId:  '',
customField: '20060623-232744'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '1155',
internalId:  '',
customField: '20060916-010149'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '2436',
internalId:  '',
customField: '20060623-232744'
};
var canonHostname = 'diywk00.verio.stngva01.us.diy-servers.net';
var accountId     = 'AVEC10IN2PQM';
var companyName   = 'mbllbiomusic';
var htmlTitle	  = 'mbllbiomusic';
var metaKeywords  = '';
var metaContents  = '';
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();
};
