日付は2011-01-28 06:34:33
、つまりdate("Y-m-d H:i:s")
です。私はそれを28th January 2011
に変換したいと思います。PHPの日付変換
どうすれば変更できますか?
日付は2011-01-28 06:34:33
、つまりdate("Y-m-d H:i:s")
です。私はそれを28th January 2011
に変換したいと思います。PHPの日付変換
どうすれば変更できますか?
使用
$dateStr = date("jS F Y", time());
日の値がゼロを招くことなくです。
このエコー日付を試してください( 'jS F Y h:i:s A')。
-1 [日付のマニュアル](http://de2.php.net/manual/en/function.date.php)を見たり、[StackOverflowを先に検索しない] (http://stackoverflow.com/search?q=convert+date+php)。どのように日付を変換し、書式を設定するかは、何度も尋ねられています。 [Ask Advice](http://stackoverflow.com/questions/ask-advice)を無視しないでください – Gordon
[PHPはある日付を別の日付形式に変換します](http://stackoverflow.com/questions/2167916/) php-convert-one-date-to-another-date-format) – Gordon