You want the client side code to referesh from data on the server without refreshing the page? You'll need to use xmlHttpRequest.
I, personally, use AJAX and the
prototype.js script, as that is what they build into Ruby on Rails, but for what you want its probably overkill.
This might be a good read to start
http://www.xml.com/pub/a/2005/02/09/...p-request.html
But google on xmlHttpRequest for other.
Basically you'l need your Javascript to trigger the xmlHttpRequest ever minute that calls a PHP script that simply returns the server time. this wil then be picked up by your javascript code to do with as it wants