Display Current Date and Time

Registered by Brian Mathis on 2010-06-15

Provide a way to for the client to pull the current date and/or time and insert it into a region.

Blueprint information

Status:
Not started
Approver:
None
Priority:
Undefined
Drafter:
None
Direction:
Needs approval
Assignee:
None
Definition:
New
Series goal:
None
Implementation:
Unknown
Milestone target:
None

Related branches

Sprints

Whiteboard

As an interim work around, this can very easily be implemented as follows with an Embedded HTML media type:

In the Embedded HTML section:
<span id="clock"></span>

And in the script section:
<script type="text/javascript">
function EmbedInit()
{
 // Init will be called when this page is loaded in the client.
 clock();
}

var tick;

function stop() {
  clearTimeout(tick);
}

function clock() {
  var ut=new Date();
  var h,m,s;
  var time=" ";
  h=ut.getHours();
  m=ut.getMinutes();
  s=ut.getSeconds();
  if(s<=9) s="0"+s;
  if(m<=9) m="0"+m;
  if(h<=9) h="0"+h;
  time+=h+":"+m+":"+s;
  document.getElementById('clock').innerHTML=time;
  tick=setTimeout("clock()",1000);
}
</script>

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.