note 56557 added to function.date

From: Date: Wed, 07 Sep 2005 11:19:29 +0000
Subject: note 56557 added to function.date
Groups: php.notes 
Request: Send a blank email to php-notes+get-94855@lists.php.net to get a copy of this message
For users who want a different language than english, you can user strftime() function in combination with setlocale() instead of date(): e.g. for german language: With date you would write: <?php echo date('l, d. F Y'); //Output: Wednesday, 07. September 2005 ?> With strftime() you can output it in german like this: <?php // Set the gloabal LC_TIME constant to german setlocale(LC_TIME, 'de_DE'); // Little bit other Syntax but better effect echo strftime('%A, %d. %B %Y'); //Output: Mittwoch, 07. September 2005 ?> Greetings, Andy! ---- Manual Page -- http://www.php.net/manual/en/function.date.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+56557 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+56557&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+56557&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+56557&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+56557&report=yes&reason=useless Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+56557&report=yes&reason=non-english Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+56557&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+56557&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#94855) next »