How to create a block to show a digital clock? I need to create a block to show a LIVE digital clock?

I tried to use the http://drupal.org/project/clock and the http://drupal.org/project/jstimer  modules but it doesn't use javascript to refresh the time, it shows the time when the page is load, to refresh the time I need to reload the page.

How can I do this?

Something like this http://drupal.org/project/timeblock but for D7
100% agree with Jimajamma above on extracting the stuff you need from the timeblock module, all it is really doing is just adding two javascript blocks with a minimal amount of formatting. For example, to replicate the 24-hour clock, all you have to do is create a new block with an 'unformatted' input format and add this code (extracted from the time block module):

&lt;span id="liveclock" style="position:relative;left:0;top:0;"&gt;
&lt;/span&gt;

&lt;script language="JavaScript"&gt;
&lt;!--

function show5(){
 if (!document.layers&amp;&amp;!document.all&amp;&amp;!document.getElementById)
 return
 var Digital=new Date()
 var hours=Digital.getHours()
 var minutes=Digital.getMinutes()
 var seconds=Digital.getSeconds()
 if (hours&lt;12)
 hours="0"+hours
 if (minutes&lt;=9)
 minutes="0"+minutes
 if (seconds&lt;=9)
 seconds="0"+seconds
myclock="&lt;strong&gt;"+hours+":"+minutes+":"+seconds+"&lt;/strong&gt;"
if (document.layers){
document.layers.liveclock.document.write(myclock)
document.layers.liveclock.document.close()
}
else if (document.all)
liveclock.innerHTML=myclock
else if (document.getElementById)
document.getElementById("liveclock").innerHTML=myclock
setTimeout("show5()",1000)
 }

$(document).ready(function(){ show5(); });


//--&gt;
&lt;/script&gt;


Quick fix to replace the body unload with a jquery $(document).ready() call, though probably not necessary inside a block.