Fixed the error in the PHP code caused by the invalid argument supplied to the date/time constructor.