diff --git a/timestamp/timestamp.lua b/timestamp/timestamp.lua new file mode 100644 index 0000000..693f91e --- /dev/null +++ b/timestamp/timestamp.lua @@ -0,0 +1,19 @@ +--- +permalink: /cgi/timestamp/index.lua +--- + +-- Set the timezone (not directly supported in Lua) +-- You'll need to handle timezone conversion manually if needed + +-- Get current time +local timestamp = os.date("%Y.%m.%d-%H:%M:%S") + +-- Get current time in milliseconds +local milliseconds = os.time() * 1000 + +-- Output the HTTP header +io.write("Content-Type: text/plain; charset=utf-8\r\n\r\n") + +-- Output result +io.write(timestamp .. '.' .. milliseconds) + diff --git a/timestamp/timestamp.php b/timestamp/timestamp.php index 42f9ca1..869b4ed 100644 --- a/timestamp/timestamp.php +++ b/timestamp/timestamp.php @@ -1,5 +1,5 @@ --- -permalink: /cgi/timestamp/ +permalink: /cgi/timestamp/obsolete.php ---