window.addEvent('domready', function(){
	initMenus();
	initMenuBtn();
});


function initMenus() {
	// mainmenu hover
	$$(".menu_item").forEach(function(element){
		var elFx = element.getFirst().effect('opacity', {wait:false,duration:580}).set(1);
		element.addEvents({
			'mouseenter': elFx.start.pass(0, elFx),
			'mouseleave': elFx.start.pass(1, elFx)
		});
	});
}

function initMenuBtn() {
	var home = document.getElementById('btn_home');
	var band = document.getElementById('btn_band');
	var media = document.getElementById('btn_media');
	var photos = document.getElementById('btn_photos');
	var friends = document.getElementById('btn_friends');
	var contact = document.getElementById('btn_contact');

	if(window.location == "http://www.theennergytrio.com/index.php") {
		home.style.display = "none";
	} else if(window.location == "http://www.theennergytrio.com/index.php/band/") {
		band.style.display = "none";	
	} else if(window.location == "http://www.theennergytrio.com/index.php/media/") {
		media.style.display = "none";
    } else if(window.location == "http://www.theennergytrio.com/index.php/photos/") {
		photos.style.display = "none";
 	} else if(window.location == "http://www.theennergytrio.com/index.php/friends/") {
		friends.style.display = "none";
	} else if(window.location == "http://www.theennergytrio.com/index.php/contact/") {
		contact.style.display = "none";
	}	
}