/* [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','6401',jdecode('Alula+Models'),jdecode(''),'/6401.html','true',[],''],
	['PAGE','6452',jdecode('Contact'),jdecode(''),'/6452.html','true',[],''],
	['PAGE','6473',jdecode('About+us'),jdecode(''),'/6473.html','true',[],''],
	['PAGE','6557',jdecode('Apply'),jdecode(''),'/6557.html','true',[],''],
	['PAGE','6494',jdecode('Promotional+Models'),jdecode(''),'/6494/index.html','true',[ 
		['PAGE','21929',jdecode('Book+Promotional+event'),jdecode(''),'/6494/21929.html','true',[],'']
	],''],
	['PAGE','15901',jdecode('Australian+Models'),jdecode(''),'/15901/index.html','true',[ 
		['PAGE','14943',jdecode('Brisbane+Model+-+Stacey'),jdecode(''),'/15901/14943.html','true',[],''],
		['PAGE','17301',jdecode('Model+Leah'),jdecode(''),'/15901/17301.html','true',[],''],
		['PAGE','17201',jdecode('Brisbane+Model+Angie'),jdecode(''),'/15901/17201.html','true',[],''],
		['PAGE','23829',jdecode('Alula+Models+-+Search'),jdecode(''),'/15901/23829.html','true',[],'']
	],''],
	['PAGE','6536',jdecode('Photography'),jdecode(''),'/6536.html','true',[],''],
	['PAGE','14901',jdecode('Interesting+links'),jdecode(''),'/14901.html','true',[],''],
	['PAGE','14922',jdecode('Forum+-+Models'),jdecode(''),'/14922.html','true',[],''],
	['PAGE','26127',jdecode('Model+Booking'),jdecode(''),'/26127.html','true',[],'']];
var siteelementCount=15;
theSitetree.topTemplateName='Family';
theSitetree.paletteFamily='D6C4AB';
theSitetree.keyvisualId='3838';
theSitetree.keyvisualName='kv_3838.jpg';
theSitetree.fontsetId='10635';
theSitetree.graphicsetId='11022';
theSitetree.contentColor='000000';
theSitetree.contentBGColor='D6C4AB';
var localeDef={
  language: 'en',
  country: 'US'
};
var theTemplate={
				name: 			'Family',
				paletteFamily: 	'D6C4AB',
				keyvisualId: 	'3838',
				keyvisualName: 	'kv_3838.jpg',
				fontsetId: 		'10635',
				graphicsetId: 	'11022',
				contentColor: 	'000000',
				contentBGColor: 'D6C4AB',
				hasFlashNavigation: 'false',
				hasFlashLogo: 	'false',
				hasFlashCompanyname: 'false',
				hasFlashElements: 'false',
				hasCompanyname: 'false',
				a_color: 		'000000',
				b_color: 		'000000',
				c_color: 		'000000',
				d_color: 		'AEAEAF',
				e_color: 		'AEAEAF',
				f_color: 		'AEAEAF',
				hasCustomLogo: 	'true',
				contentFontFace:'Verdana, Arial, Helvetica, sans-serif',
				contentFontSize:'12',
				useFavicon:     'true'
			  };
var webappMappings = {};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6401',
internalId:  '',
customField: '20090703-073309'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6557',
internalId:  '',
customField: '20090509-192329'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6452',
internalId:  '',
customField: '20090702-055315'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6473',
internalId:  '',
customField: '20080801-030228'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6494',
internalId:  '',
customField: '20080727-210520'
};
webappMappings['1006']=webappMappings['1006-1006']={
webappId:    '1006',
documentId:  '6401',
internalId:  '1006',
customField: '1006'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '6536',
internalId:  '',
customField: '20080810-195201'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '17201',
internalId:  '',
customField: '20080801-163719'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '17301',
internalId:  '',
customField: '20080728-205002'
};
webappMappings['1003']=webappMappings['1003-aendu0in2v0m11ae630ec54']={
webappId:    '1003',
documentId:  '14922',
internalId:  'aendu0in2v0m11ae630ec54',
customField: 'en:US'
};
webappMappings['7060']=webappMappings['7060-c965e7d4df176034efad437f44c64e51']={
webappId:    '7060',
documentId:  '14943',
internalId:  'c965e7d4df176034efad437f44c64e51',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14943',
internalId:  '',
customField: '20080801-165248'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14922',
internalId:  '',
customField: '20080702-195223'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '14901',
internalId:  '',
customField: '20080801-170133'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '15901',
internalId:  '',
customField: '20080729-011452'
};
webappMappings['7008']=webappMappings['7008-6690']={
webappId:    '7008',
documentId:  '21929',
internalId:  '6690',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '21929',
internalId:  '',
customField: '20080727-211607'
};
webappMappings['7060']=webappMappings['7060-888b6b329b00f4601bec5fb6eafb01ec']={
webappId:    '7060',
documentId:  '17301',
internalId:  '888b6b329b00f4601bec5fb6eafb01ec',
customField: 'language:en;country:US;'
};
webappMappings['7060']=webappMappings['7060-33b0a30735c73302d152c6a7b730a078']={
webappId:    '7060',
documentId:  '17201',
internalId:  '33b0a30735c73302d152c6a7b730a078',
customField: 'language:en;country:US;'
};
webappMappings['8002']=webappMappings['8002-search']={
webappId:    '8002',
documentId:  '23829',
internalId:  'search',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '23829',
internalId:  '',
customField: '20080728-221349'
};
webappMappings['7008']=webappMappings['7008-6886']={
webappId:    '7008',
documentId:  '26127',
internalId:  '6886',
customField: 'language:en;country:US;'
};
webappMappings['5000']=webappMappings['5000-']={
webappId:    '5000',
documentId:  '26127',
internalId:  '',
customField: '20080801-164616'
};
var canonHostname = 'cmworker02.yourhostingaccount.com';
var accountId     = 'AENDU0IN2V0M';
var companyName   = 'Alula+Models';
var htmlTitle	  = 'Alula+Models+Australia+-+Photo+Models%2C+Promotional+Models%2C+Promotional+Services';
var metaKeywords  = 'Photo+Models%2C+Promo+Models%2C+Promotional+Models%2C+Promo+Girls%2C+Promo+Guys%2C+Promo+Staff%2C+Promo+Banners%2C+trade+show+staff%2C+Trade+show+displays%2C+Bikini+Models%2C+Swimwear+Models%2C+Models+Brisbane%2C+Models+Melbourne%2C+Models+Gold+Coast%2C+Models+Queensland%2C+Models+Victoria%2C+Models+Australia%2C+Model+Portfolios%2C+Photographic+Models%2C+Model%2C+Modeling%2C+Models.';
var metaContents  = 'Alula+Models+Australia+-+Value+in+your+Brand+%2C+Photographic+Models%2C+Promotional+Models%2C+Promotional+Services+-+Promo+Girls%2C+Promo+Guys.+Promotional+Girls+Brisbane%2C+Promotional+Girls+Melbourne%2C+Promotional+Girls+Gold+Coast.+Contact+Alula+Models+to+ensure+success+at+your+tradeshow+or+event..';
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();
};
