function toggleStreamsBox(sb_id, heightofanimation, sbutton_id, entryId) // (id of box, final height, id of button)
{

		var checkVar = document.getElementById(sb_id).style.height;

		if (checkVar == '' || checkVar == "0px")
		{
				document.getElementById('bl-'+entryId).style.display='none';
				
				document.getElementById(sb_id).style.display = "block"; // Unhide streamsbox

				var openBoxParams = { height: {to: heightofanimation}}; // animation attributes

				var openStreamsBox = new YAHOO.util.Anim(sb_id, openBoxParams, 0.4, YAHOO.util.Easing.easeBothStrong);
				openStreamsBox.animate();
		}
		else
		{
				var closeBoxParams = { height: {to: 0}}; // animation attributes

				var closeStreamsBox = new YAHOO.util.Anim(sb_id, closeBoxParams, 0.4, YAHOO.util.Easing.easeBothStrong);
				closeStreamsBox.animate();

				function hideSB(id) {
						document.getElementById(id).style.display = "none"; // hide streamsbox
				}
				setTimeout(function(){hideSB(sb_id);}, 360); // Wait 360ms for the animation to finish up, and then hide the streams box
				
				document.getElementById('bl-'+entryId).style.display='block';
		}
		
		toggleStreamsButton(sbutton_id);
}


function toggleStreamsButton(sbutt_id){
	var classofbutton = document.getElementById(sbutt_id).className;
	if (classofbutton == 'streams'){
		document.getElementById(sbutt_id).className = 'streams-up';
	}else{
		document.getElementById(sbutt_id).className = 'streams';// MAKE STREAMS DOWN
	}
}

