PHP Error Reporting; OS X on Localhost

A .php document has been transferred from one mac to a second mac.

The browser connects to localhost.

The php.ini files are identical.

On the second machine we get the error:


Warning: date() [function.date]: 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/London' for 'BST/1.0/DST' instead in

The page does not view.

Could anyone please help?
smudgemouseAsked:
Who is Participating?
 
themrrobertConnect With a Mentor Commented:
You are running a different version of PHP on the other mac.

Add this line :

date_default_timezone_set('America/Los_Angeles');

(or date_default_timezone_set('Europe/London'); if you are over there)

to the top of your 'highest up' include file. like 'globals.inc'.

also, in your php.ini you could add
date.timezone = "Europe/London"

In any case, where it was once not required, now it is. Its unfortunate, but you have to do it :)


0
All Courses

From novice to tech pro — start learning today.