What would cause the code below to not run? :     <script>
        //<![CDATA[
        var displayCurrentTime = new function() {
            // Get values...
            var sysHour = getHours();    // Get Hours
            var curHour = 0;             // Initialize current hour (12 hr format)
            var morningEvening = "AM";   // Initialize AM/PM notation
                
            if (sysHour < 13) {          // If it's in the morning, set time as is.
                curHour = sysHour;
                morningEvening = "AM"
            } else {
                curHour = sysHour - 12;  // If it's in the evening, subtract 12 from the value and use "PM"
                morningEvening = "PM"
            }
            var curMins: getMinutes;     // Get current minutes...
                
            // Capture the ID of the notification bar div, and compose a string from the above values.
            var notificationBar = document.getElementById("notificationBar");
            var dateTimeString = curHour + ":" + curMins + " " + morningEvening;
                
                
            // All that code above files into this fun stuff.
            notificationBar.innerHTML = dateTimeString;
        }
            
        window.setInterval(function(){ displayCurrentTime(); }, 1000);
        //]]>
    </script>

I've been reading up some information and I wanted to create a simple script that grabs the hour and minute, does some calculations to determine if it's AM or PM, creates a string variable from those results, and then slips it inside of a specific DIV element.  It does this every second.

Most of the code I've written seems to make sense based on what I've read.  In the beginning I've tried using function displayCurrentTime() {} as well as what you see below (var displayCurrentTime = new function() {}) and neither seem to work.  I cannot get my text to display in the page.  Note: the ID of the div is notificationBar, just as it is here.

Is there anything in this code that makes no sense, or does this actually warrant posting the full HTML?