mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 08:58:56 +00:00
added some missing placeholders like '%e' from the Open Groups
strftime() specification git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@24115 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
73865b1056
commit
39172113a8
1 changed files with 89 additions and 34 deletions
|
@ -667,78 +667,131 @@ echo strftime ("Last day in Feb 2000 is: %d", $lastday);
|
|||
<itemizedlist>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%a - abbreviated weekday name according to the current locale
|
||||
%a - abbreviated weekday name according to the current locale
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%A - full weekday name according to the current locale
|
||||
%A - full weekday name according to the current locale
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%b - abbreviated month name according to the current locale
|
||||
%b - abbreviated month name according to the current locale
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%B - full month name according to the current locale
|
||||
%B - full month name according to the current locale
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%c - preferred date and time representation for the current
|
||||
locale
|
||||
%c - preferred date and time representation for the current
|
||||
locale
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%d - day of the month as a decimal number (range 00 to 31)
|
||||
%C - century number (the year divided by 100 and truncated
|
||||
to an integer, range 00 to 99)
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%H - hour as a decimal number using a 24-hour clock (range 00
|
||||
to 23)
|
||||
%d - day of the month as a decimal number (range 00 to 31)
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%I - hour as a decimal number using a 12-hour clock (range 01
|
||||
to 12)
|
||||
%D - same as %m/%d/%y
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%j - day of the year as a decimal number (range 001 to 366)
|
||||
%e - day of the month as a decimal number, a single digit is
|
||||
preceded by a space (range ' 1' to '31')
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%m - month as a decimal number (range 1 to 12)
|
||||
%h - same as %b
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%M - minute as a decimal number
|
||||
%H - hour as a decimal number using a 24-hour clock
|
||||
(range 00 to 23)
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%p - either `am' or `pm' according to the given time value, or
|
||||
the corresponding strings for the current locale
|
||||
%I - hour as a decimal number using a 12-hour clock
|
||||
(range 01 to 12)
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%S - second as a decimal number
|
||||
%j - day of the year as a decimal number (range 001 to 366)
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%U - week number of the current year as a decimal number,
|
||||
starting with the first Sunday as the first day of the first
|
||||
week
|
||||
%m - month as a decimal number (range 1 to 12)
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%M - minute as a decimal number
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%n - newline character
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%p - either `am' or `pm' according to the given time value, or
|
||||
the corresponding strings for the current locale
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%r - time in a.m. and p.m. notation
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%R - time in 24 hour notation
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%S - second as a decimal number
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%t - tab character
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%T - current time, equal to %H:%M:%S
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%u - weekday as a decimal number [1,7],
|
||||
with 1 representing Monday
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%U - week number of the current year as a decimal number,
|
||||
starting with the first Sunday as the first day of the first
|
||||
week
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
|
@ -751,47 +804,47 @@ echo strftime ("Last day in Feb 2000 is: %d", $lastday);
|
|||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%W - week number of the current year as a decimal number,
|
||||
starting with the first Monday as the first day of the first
|
||||
week
|
||||
%W - week number of the current year as a decimal number,
|
||||
starting with the first Monday as the first day of the first
|
||||
week
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%w - day of the week as a decimal, Sunday being 0
|
||||
%w - day of the week as a decimal, Sunday being 0
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%x - preferred date representation for the current locale
|
||||
without the time
|
||||
%x - preferred date representation for the current locale
|
||||
without the time
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%X - preferred time representation for the current locale
|
||||
without the date
|
||||
%X - preferred time representation for the current locale
|
||||
without the date
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%y - year as a decimal number without a century (range 00 to
|
||||
99)
|
||||
%y - year as a decimal number without a century
|
||||
(range 00 to 99)
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%Y - year as a decimal number including the century
|
||||
%Y - year as a decimal number including the century
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%Z - time zone or name or abbreviation
|
||||
%Z - time zone or name or abbreviation
|
||||
</simpara>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<simpara>
|
||||
%% - a literal `%' character
|
||||
%% - a literal `%' character
|
||||
</simpara>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
|
@ -813,7 +866,9 @@ print (strftime ("%A.\n"));
|
|||
</para>
|
||||
<para>
|
||||
See also <function>setlocale</function> and
|
||||
<function>mktime</function>.
|
||||
<function>mktime</function> and the <ulink
|
||||
url="http://www.opengroup.org/onlinepubs/7908799/xsh/strftime.html">
|
||||
Open Group specification of <function>strftime()</function></ulink>.
|
||||
</para>
|
||||
</refsect1>
|
||||
</refentry>
|
||||
|
|
Loading…
Reference in a new issue