My hosting provider upgraded to PHP 5.3 and I started to get escaped quotes. So, following advice on this forum, I contacted the provider who told me I could only turn off magic_quotes_gpc on a directory by directory basis using a directory based php.ini containing
magic_quotes_gpc=Off
so far so good, except, on launching the manager I get this error message (repeated many times for each of the includes that use the strtotime() function.
If I remove the php.ini then the error disappears.
Any ideas what is happening and how to get around it?
Warning: 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 'UTC' for 'UTC/0.0/no DST' instead in /home/farscape/public_html/manager/includes/rss.inc.php on line 50
[ed. note: Chris Pink last edited this post 14 years, 8 months ago.]
-
☆ A M B ☆
- 24,524 Posts
You will only need one custom php.ini file in the /manager/ directory.
You need to have one of these files in every directory where a .php file will be run, and in MODx there are only two .php files that actually run, the index.php file in the installation's root (for the front-end, and unless you're saving stuff through forms on the front-end this isn't an issue) and the index.php in the /manager/ folder. All the other .php files in a MODx installation are included, not run independently.
The proper way to have a custom php.ini file is to make a copy of the main php.ini file, then change or add the required settings. In your custom php.ini file you'll need to add a line to set the correct date.timezone setting.
http://www.php.net/manual/en/datetime.configuration.php#ini.date.timezone