Possible Duplicate:
PHP Configuration: It is not safe to rely on the system’s timezone settings
Php errors: Warning: require() [function.require]: open_basedir restriction in effect
My first question here at stackoverflow (please be nice :P)
Why is my apache showing this error?
Severity: Warning
Message: strtotime() [function.strtotime]: 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. We selected ‘Europe/Berlin’ for ‘CEST/2.0/DST’ instead
Environment
I’m using MacOS Mountain Lion’s (10.8.2) Apache.
Things I’ve tried
-
I’ve tried to rename my /etc/php.ini.default to /etc/php.ini but when I do, php won’t compile anymore.
-
I’ve also tried to uncomment this line (in the php.ini):
date.timezone = ‘Europe/Berlin’
But it doesn’t do anything. As soon as I restart apache the php stops working.
Any ideas?
Thanks in advance.
This is PHP message, not Apache. And it is because, as messages indicates, of misconfiguration of your PHP. Edit your correct
php.inifile (usually, it ends in/etc/php5/<FLAVOUR>/php.init, where “FLAVOUR” can beapache2,clior (most likely)cgi(orcgi-bin), for example/etc/php5/apache2/php.ini. Then uncommentdate.timezoneline and put your timezone, i.e.