// create the necessary arrays

var subSectionIdArray = new Array('eat','shop','drink','sleep');
var subSectionNameArray = new Array('EAT','SHOP','DRINK','SLEEP');
var subSectionUrlArray = new Array('becco.html'
							,'haighs-chocolates.html'
							,'city-wine-shop.html'
							,'the-como-melbourne.html');

var subNav = '<div id=\"bottomNav\">\n';
subNav += '<ul id=\"secondaryNav\">\n';
			
for(var i=0; i<subSectionIdArray.length; i++){
	if(subsection == subSectionIdArray[i]){
		subNav += '<li class=\"divide\" id=\"'+subSectionIdArray[i]+'\"><a href=\"'+subSectionUrlArray[i]+'\" class=\"selected\">'+subSectionNameArray[i]+'</a></li>\n';
	}else{
		subNav += '<li class=\"divide\" id=\"'+subSectionIdArray[i]+'\"><a href=\"'+subSectionUrlArray[i]+'\">'+subSectionNameArray[i]+'</a></li>\n';
	}
	subNav += '<li><img src="images/global/nav/nav-divider-purple.png" alt=""/></li>\n';
}

subNav += '</ul>\n';
subNav += '</div>\n';

document.write(subNav);