【发布时间】:2013-10-03 02:56:04
【问题描述】:
$date = date_create('2013-10-27');// This is the date that inputed in textbox and that format is (Y-m-d)
$date = date_create('2013-10-10');// and if i click the button i want to force change the 27 to 10?
我应该使用 date_modify 并做一些循环,还是有其他方法可以简单地更改它而不是循环。
【问题讨论】:
-
您接受的答案不是最好的。我会推荐Glavic's answer。