Solve PHP error – Warning: strftime() [function.strftime]

If you the following error

Warning: strftime() [function.strftime]: It is not safe to rely on the system’s timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier.

To solve this waring please add the following line to the php.ini file where the PHP file resides.

date.timezone = "Europe/London"

(OR) add the following code to the PHP file

<?php date_default_timezone_set('Europe/London'); ?>

 

Leave a Reply

Your email address will not be published.

five × one =