douan3414 2018-06-12 20:53
浏览 882

警告:date_diff()要求参数1为DateTimeInterface,其中给出布尔值

I receive these errors Please help me

Warning : date_diff() expects parameter 1 to be DateTimeInterface, boolean given in on line 72

Fatal error : Uncaught Error: Call to a member function format() on boolean in ___ Stack trace: #0 {main} thrown in on line 73

here's my code

it is the code pic

  • 写回答

1条回答 默认 最新

  • doubu5154 2018-06-14 21:36
    关注

    date_create() is failing to create a date and it is returning FALSE rather than a DateTimeInterface. Hence the error, expects parameter 1 to be DateTimeInterface, boolean given. Double check your posted value to see that it is usable.

    date_diff() returns false and causes the next error.

    评论

报告相同问题?