// File JScript

function showSubMenu(menu)
        {
            var subMenu = document.getElementById(menu.id + "_sub");
            if (subMenu != null)
                subMenu.style.display = "block";
        }

        function hideSubMenu(menu)
        {
            var subMenu = document.getElementById(menu.id + "_sub");
			if (subMenu != null)
                subMenu.style.display = "none";

        }

        function menuItemOver(event)
        {
            var menuItem = event.srcElement == null ? event.target : event.srcElement;
            if (menuItem != null  && menuItem.className != "menuBar")
            {
                if (menuItem.tagName == "A")
                    menuItem = menuItem.parentNode;
                menuItem.style.backgroundColor = "";
            }
        }

        function menuItemOut(event)
        {
            var menuItem = event.srcElement == null ? event.target : event.srcElement;
            if (menuItem != null  && menuItem.className != "menuBar")
            {
                if (menuItem.tagName == "A")
                    menuItem = menuItem.parentNode;
                menuItem.style.backgroundColor = "";
            }
        }

        function debugOut(text)
        {
            document.getElementById("logo").innerHTML = text;
        }

        function toggleVisibility(element)
        {
            if (element.className == "invisible")
                element.className = "";
            else
                element.className = "invisible";
        }

		function openNewsPopUp(openPopUp)
		{
			    var popUpWindowWidth = 650;
			    var popUpWindowHeight = 550;
			   	var popUpWindowLeftPosition = Math.floor((screen.width-popUpWindowWidth)/2);
			  	var popUpWindowTopPosition = Math.floor((screen.height-popUpWindowHeight)/2);
			  	//var popUpWindowScrollBar = yes;*/

			  	var style = "menubar=no, toolbar=no, scrollbar=yes";

			    window.open(openPopUp,"","width=" + popUpWindowWidth + ",height=" + popUpWindowHeight + ",top=" + popUpWindowTopPosition + ",left=" + popUpWindowLeftPosition, style);
			}

			function showAlertContainer() {

			    var alertBanner = document.getElementById('alertBannerHome');

			    alertBanner.style.display = "block";
			}

			function hideAlertContainer() {

			    var alertBanner = document.getElementById('alertBannerHome');

			    alertBanner.style.display = "none";
			}

			function showPlayScriptComedy(author) {

			    var idData = author.id.split('_');
                
                var table = document.getElementById('playScript_' + idData[1]);
			    if (table.style.display == 'block') {
			        table.style.display = 'none';
			    }
			    else {
			        table.style.display = "block";
			    }
			}

function showArchive(archiveTitle)
{
    if(document.getElementById('stagesArchive').style.display == 'none')
    {
        document.getElementById('stagesArchive').style.display = 'block';
    }
    else
    {
        document.getElementById('stagesArchive').style.display = 'none';
    }
}