This all works as required. The one issue I'm having though is that when I load my record/page the clock does not load until I refresh the page.
document.getElementBy("mydiv").innerHTML ="Hello" & other setter methods do not work on the page load. I thought I could use the afterRender as per the documentation but I cannot get this to work.
If I check
document.readyState == "complete" it returns true but my subsequent HTML writing does not appear.
I want my clock to appear when the page loads, not on a refresh. Should I not be able to do this via
document.getElementBy("mydiv").whatever or do I require jQuery? I would not have thought jQuery was needed for this.