questions about strftime
| From: | Harald Ponce de Leon | Date: | Mon, 10 Apr 2000 00:08:22 +0000 |
| Subject: | questions about strftime | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-13348@lists.php.net to get a copy of this message | ||
strftime seems to be lacking some features that the normal date command
has..
i have some suggestions.. these are in regard to php4RC1..
(1) date has 'n' (month without leading 0) and 'j' (days without leading 0)
and strftime has only %d and %m .. these are with leading zeros.. is it
possible to make extra specifiations so we can choose to not have the
leading zeros?
(2) the suffix is missing from strftime, 'S' in the date function.. can this
be implemented?
(3) when strftime uses the german (de_DE) locale, high german characters
(äöü) are directly written when showing the day and month.. shouldnt this be
written in html format? such as ü ö etc..
(4) can we customize the 'preferred' date representations for the selected
locale? for en_US an example preferred date (%x) is
03/20/00
i would like the century to be shown.. can we have more specifiers that show
some more examples of displaying the date?
why is this important? for a site thats multilingual, keeping the strftime
syntax the same is essential - using the same syntax in a german locale, the
string returned would be
20.03.2000 (showing the century)..
this can cause an inconsistency of displaying the date in various locales..
(5) when i have the LC_ALL set to german (de_DE), the decimal point is a
comma, eg 3,20.. when using number_format on this, apache core dumps.. i
dont think it properly detects the LC_NUMERIC value?
example,
$a = 3;
$b = 4;
$sum = $a + $b;
echo number_format($sum, 2);
sometimes it returns 7,00.. sometimes IE reports a page loading error.. and
it core dumps :(
thanks for your time..
Harald