I'm trying to add this clock into my code but it does not show on the page, anyone know why? I have tried copying it in notepad but no success.
http://jsfiddle.net/yS4da/2707/
<code id="time"></code>
<script>
var midnight = "0:00:00";
var now = null;
setInterval(function () {
now = moment().format("H:mm:ss");
if (now === midnight) {
alert("Hi");
}
$("#time").text(now);
}, 1000);
</script>
If you look into the developer console (F12) you will see that "moment ist no defined". The fiddle is using moment.js which you need to include. Consider that the project is considered as legacy.