        // script controls two lists (RSS and Viral) set to display:none by default.
        // only one list is allowed to display at a time.
        // script checks to see which list is being acted upon, sets the other list to display:none, and then changes the display of the active list
        var RSSListExpanded = false;
        var ViralListExpanded = false;

        function menuControl (source) {// source is the span that the user clicks on
            var sourceName = source.parentNode.id; // sourceName is the id of the LI that contains the nested UL
            source = source.parentNode; // source is changed to the (OBJECT) LI that containst the nested UL (and the on-click span)

            var RSSTub = document.getElementById("AddThis");
            var RSSMenu = document.getElementById("RSSList");
            var ViralTub = document.getElementById("ShareThis");
            var ViralMenu = document.getElementById("ViralList");

            if (sourceName == RSSTub.id) {
                ViralMenu.style.display = "none";
                ViralListExpanded = false;
                ViralTub.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/open.gif)";
                if (RSSListExpanded == false) {
                    RSSTub.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/close.gif)";
                    RSSMenu.style.display = "block";
                    RSSListExpanded = true;
                } else {
                    RSSMenu.style.display = "none";
                    RSSListExpanded = false;
                }
            } else if (sourceName == ViralTub.id) {
                RSSMenu.style.display = "none";
                RSSListExpanded = false;
                RSSTub.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/rss_icon.gif)";
                if (ViralListExpanded == false) {
                    ViralTub.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/close.gif)";
                    ViralMenu.style.display = "block";
                    ViralListExpanded = true;
                } else {
                    ViralTub.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/open.gif)";
                    ViralMenu.style.display = "none";
                    ViralListExpanded = false;
                }
            }
        }

        function icon (source, action) {// source is the span that the user clicks on
            source = source.parentNode; // source is changed to the (OBJECT) LI that containst the nested UL (and the on-click span)
            if (action == "swap") {
                source.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/open.gif)";
            } else if (action == "restore") {
                if (RSSListExpanded == false) {
                    source.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/rss_icon.gif)";
                } else {
                    source.style.backgroundImage = "url(" + contextPath + "\/resources\/images\/icons\/close.gif)";
                }
            }
        }