Wednesday, December 26, 2001

Here's how to get the current time into your page, in a 24-hour format, European-style — add the following macro to your template:

<%<br /> local (day, month, year, hour, minute, second);<br /> date.get (now, @day, @month, @year, @hour, @minute, @second);<br /> hour = string.padWithZeros (hour, 2);<br /> minute = string.padWithZeros (minute, 2);<br /> second = string.padWithZeros (second, 2);<br /> return (hour + "." + minute + "&apos;" + second)<br /> %>

The macro expands to something like this: 03.36'02