Object of class DateTime could not be converted to string

后端 未结 7 570
灰色年华
灰色年华 2020-11-27 19:16

I have a table with string values in the format of Friday 20th April 2012 in a field called Film_Release

I am looping through and i want to convert

相关标签:
7条回答
  • 2020-11-27 20:09

    Use this: $newDate = $dateInDB->format('Y-m-d');

    0 讨论(0)
提交回复
热议问题