Wednesday, October 9, 2013

[PHP]A PHP Error was encountered It is not safe to rely on the system's timezone settings.....

PHP Error Message:

A PHP Error was encountered

Severity: Warning
Message: include() [function.include]: 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 'UTC' for '8.0/no DST' instead
Filename: maids/m_all.php
Line Number: 26
 
As my own experience,
If you don't want config the server,
it usually causes of some php errors.

How to make the page run ?
So you can vist the file shown in the error message,
and look for line number 26.
It would be sth there...


Can you see something missing in the red square ?

I missed a colon at the end of the line (line26)

* * *
After added the colon,
save the page then refresh in browser,
the page run again.

The Error is not related to the server timezone setting,
So don't know the what cause the message :
"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().."

If you have this problem , let look for the php error in your page first : )

No comments :

Post a Comment