DateTime::getLastErrors

PHP 5 >= 5.3.0, PHP 7, PHP 8
DateTime::getLastErrors - Returns the warnings and errors
Manual
Code Examples

Example #1 DateTime::getLastErrors example

Result: Array ( [warning_count] => 1 [warnings] => Array ( [6] => Double timezone specification ) [error_count] => 1 [errors] => Array ( [0] => The timezone could not be found in the database ) )
PHP Version:


Function DateTime::getLastErrors:

Date and Time Functions

Most used PHP functions