-1
可能重複:
How to echo 1st and 15th of the month in php插入新的一年日曆雙月調度
能夠打印出2012年12月1日&二○一二年十二月一十五日,但不能得到繼續過去那一點到2013年1月1日2013年1月15日依次等:
for($i=1;$i<=12;$i++){
date('M 1, Y', strtotime($i . "/1/" . date("Y")));
date('M 15, Y', strtotime($i . "/15/" . date("Y")));
}
如果你已經在你以前的問題上使用了我的解決方案,使用'DateTime'對象,而不是這個怪物,對你來說會更容易:) –