Home
About
Policies
FAQ
Forums
Registration
Password Recovery

Ftime (MPI)

From Tapestries MUCK

(Difference between revisions)
Jump to: navigation, search
 
(4 intermediate revisions not shown)
Line 1: Line 1:
-
[[Category:MPI functions]]
+
[[Category:functions (MPI)]][[Category:Time Functions (MPI)]]
=ftime=
=ftime=
<mpi>{ftime:format}
<mpi>{ftime:format}
{ftime:format,tz}
{ftime:format,tz}
{ftime:format,tz,secs}</mpi>
{ftime:format,tz,secs}</mpi>
-
Returns a time string in the format you specify.  See 'man timefmt' for the %subs that you can use in the format string.
+
Returns a time string in the format you specify.
-
If specified, tz is the number of seconds offset from GMT. If specified, secs is the systime to use, instead of the current time.  <mpi>{ftime:%x %X %Y,{tzoffset},0}</mpi> will return the date and time for systime 0, for the local time zone of the server.
+
If specified, tz is the number of seconds offset from GMT. If specified, secs is the systime to use, instead of the current time.  <mpi>{ftime:%x %X %Y,{tzoffset},0}</mpi> will return the date and time for systime 0, for the local time zone of the server.
 +
 
 +
The format string is ascii text with formatting commands:
 +
  %% -- "%"
 +
  %a -- abbreviated weekday name.
 +
  %A -- full weekday name.
 +
  %b -- abbreviated month name.
 +
  %B -- full month name.
 +
  %C -- "%A %B %e, %Y"
 +
  %c -- "%x %X"
 +
  %D -- "%m/%d/%y"
 +
  %d -- month day, "01" - "31"
 +
  %e -- month day, " 1" - "31"
 +
  %h -- "%b"
 +
  %H -- hour, "00" - "23"
 +
  %I -- hour, "01" - "12"
 +
  %j -- year day, "001" - "366"
 +
  %k -- hour, " 0" - "23"
 +
  %l -- hour, " 1" - "12"
 +
  %M -- minute, "00" - "59"
 +
  %m -- month, "01" - "12"
 +
  %p -- "AM" or "PM"
 +
  %R -- "%H:%M"
 +
  %r -- "%I:%M:%S %p"
 +
  %S -- seconds, "00" - "59"
 +
  %T -- "%H:%M:%S"
 +
  %U -- week number of the year. "00" - "52"
 +
  %w -- week day number, "0" - "6"
 +
  %W -- week# of year, starting on a monday, "00" - "52"
 +
  %X -- "%H:%M:%S"
 +
  %x -- "%m/%d/%y"
 +
  %y -- year, "00" - "99"
 +
  %Y -- year, "1900" - "2155"
 +
  %Z -- Time zone.  "GMT", "EDT", "PST", etc.

Latest revision as of 05:16, 14 April 2007

ftime

{ftime:format}
{ftime:format,tz}
{ftime:format,tz,secs}

Returns a time string in the format you specify.

If specified, tz is the number of seconds offset from GMT. If specified, secs is the systime to use, instead of the current time.

{ftime:%x %X %Y,{tzoffset},0}
will return the date and time for systime 0, for the local time zone of the server.

The format string is ascii text with formatting commands:

  %% -- "%"
  %a -- abbreviated weekday name.
  %A -- full weekday name.
  %b -- abbreviated month name.
  %B -- full month name.
  %C -- "%A %B %e, %Y"
  %c -- "%x %X"
  %D -- "%m/%d/%y"
  %d -- month day, "01" - "31"
  %e -- month day, " 1" - "31"
  %h -- "%b"
  %H -- hour, "00" - "23"
  %I -- hour, "01" - "12"
  %j -- year day, "001" - "366"
  %k -- hour, " 0" - "23"
  %l -- hour, " 1" - "12"
  %M -- minute, "00" - "59"
  %m -- month, "01" - "12"
  %p -- "AM" or "PM"
  %R -- "%H:%M"
  %r -- "%I:%M:%S %p"
  %S -- seconds, "00" - "59"
  %T -- "%H:%M:%S"
  %U -- week number of the year. "00" - "52"
  %w -- week day number, "0" - "6"
  %W -- week# of year, starting on a monday, "00" - "52"
  %X -- "%H:%M:%S"
  %x -- "%m/%d/%y"
  %y -- year, "00" - "99"
  %Y -- year, "1900" - "2155"
  %Z -- Time zone.  "GMT", "EDT", "PST", etc.
Personal tools
Namespaces
Variants
Actions
navagation
information
wiki
Toolbox