MISC

internet time resources
This ASP Script comes from:
Craig Newell

-- link--

This code is for ASP server scripts.  Thanks goes to Craig Newell (of Microsoft's MSN Update Council) for releasing this code.

put this script onto your website

<% @ Language=VBScript %>
<%
Call writeSwatchTime
%>
<SCRIPT LANGUAGE=JScript RUNAT=Server>
function writeSwatchTime()
{
var s="";
d = new Date();
s += (d.getUTCHours()*3600*1000 + d.getUTCMinutes()*60*1000 + d.getUTCSeconds()*1000 + 3600000);
beats = s/86400
RoundedBeats = Math.round(beats);
if (RoundedBeats > 1000){
realBeats = "@0" + RoundedBeats - 1000
}
if (RoundedBeats < 100){
realBeats = "@0" + RoundedBeats
}
else{
realBeats = "@" + RoundedBeats
}
Response.Write(realBeats);
}
</SCRIPT>


main     news     about      documents      message board      directory     resources


24 Jan 99@865.31

© 1999 Ryan J. Thiessen (mail)
This page is not affiliated with Swatch® AG (www.swatch.com)