Re: Bug #17060 Updated: Request: localization of strtotime
| From: | Markus Fischer | Date: | Tue, 07 May 2002 14:01:16 +0000 |
| Subject: | Re: Bug #17060 Updated: Request: localization of strtotime | ||
| References: | 1 2 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-83789@lists.php.net to get a copy of this message | ||
Hi,
why not just depend on the current locale (if this feature
ever gets implemented) ?
- Markus
On Tue, May 07, 2002 at 01:48:37PM -0000, giank@geginformatica.it wrote :
> ID: 17060
> Updated by: giank@geginformatica.it
> Reported By: giank@geginformatica.it
> Status: Analyzed
> Bug Type: Feature/Change Request
> Operating System: Red Hat 7.1
> PHP Version: 4.2.0
> New Comment:
>
> int strtotime ( string time [, int now])
>
> is the actual function. As it gets even a complex input from the string
> "time", I think it's difficult to emulate these functionality in a
> localized fashion. However, much of the international users are
> concerned about the output of the function. That could be modified
> without such a difficulty. Here's a proposal
>
> int strtotime ( string time [, int now] [, string ccode])
>
> where the optional string "ccode" handles the localization request.
> Giving IT the result will be in Italian, EN or US for plain English, DE
> for German, FR for French and so on.
>
> So when requesting a date string, outputting in French, the software
> only has to know the country specific position of the substrings week,
> month, day, year and the name of weeks and months in that language.
> This could not work for other calendar dates, as chinese.
> Submitting 10+ languages could be a matter of hours work, and backward
> compatibility should not be an issue, as the parameter "ccode" is
> optional. This could be a little step for the PHP source code, but a
> big step for the PHP community worldwide.
--
Please always Cc to me when replying to me on the lists.
GnuPG Key: http://guru.josefine.at/~mfischer/C2272BD0.asc
"I'm not stupid, you know? :)" - Jani Taskinen