<![CDATA[ Evo 1.0.15 Need to fix Manager/includes/ for Warning: strtotime() for PHP 5.5 upgrade - My Forums]]> https://forums.modx.com/thread/?thread=98897 <![CDATA[Evo 1.0.15 Need to fix Manager/includes/ for Warning: strtotime() for PHP 5.5 upgrade]]> https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534741
AddHandler application/x-httpd-php55 .php

front end is fine, but /manager delivers 3 files all with the same error:

----
Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone.
----

manager/includes/rss.inc.php on line 49 =
$pubdate = $modx->toDateFormat(strtotime($pubdate));

manager/includes/document.parser.class.inc.php on line 2503 =
$strTime = strftime($dateFormat . " %H:%M:%S", $timestamp);

manager/actions/welcome.static.php on line 175 =
$html.= "<tr bgcolor='#FFFFFF'><td><b>".$activeusers['username']."</b></td><td>$webicon ".abs($activeusers['internalKey'])."</td><td>".$activeusers['ip']."</td><td>".strftime('%H:%M:%S', $activeusers['lasthit']+$server_offset_time)."</td><td>$currentaction</td></tr>";
}

I saw an earlier post about using a php.ini file.. but that doesn't seem to work. Any ideas of how to fix these three files?





]]>
hollyvalero Nov 24, 2015, 12:02 PM https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534741
<![CDATA[Re: Evo 1.0.15 Need to fix Manager/includes/ for Warning: strtotime() for PHP 5.5 upgrade]]> https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534805 Quote from: iusemodx at Nov 25, 2015, 04:06 PM
If you are uploading a "php.ini" file you have to upload it to both the root and manager folders.

** Okay that was my problem. php.ini file at root -- but not in the manager. Once I popped it in there with the time zone? The errors went away. THANK YOU!!!]]> hollyvalero Nov 25, 2015, 11:22 AM https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534805 <![CDATA[Re: Evo 1.0.15 Need to fix Manager/includes/ for Warning: strtotime() for PHP 5.5 upgrade (Best Answer)]]> https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534801
If you already have a "php.ini" file on your server and you have the rights to modify it (dedicated server) you can add the date time zone to it.

If your set-up doesn't have a "php.ini" file or you don't have the rights to modify it - upload a new file with the following in it:

date.timezone = Europe/London


If your timezone is different, you can view a list of valid timezones here

I have tested this in the following environments: PHP 5.3, 5.4, 5.6]]>
iusemodx Nov 25, 2015, 10:06 AM https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534801
<![CDATA[Re: Evo 1.0.15 Need to fix Manager/includes/ for Warning: strtotime() for PHP 5.5 upgrade]]> https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534791 I think you should have hit this problem with PHP 5.3 earlier - or maybe that's using a different php.ini file?

** It looks like there's a global php.ini file that I can't edit...

The htaccess file includes:


AddHandler application/x-httpd-php53 .php <-- I added this to keep it at 5.3

#php_flag register_globals Off
AddDefaultCharset utf-8
#php_value date.timezone "America/New_York" <-- uncommenting leads to global server error


<IfModule php5_module> <-- adding this doesn't fix it either.
php_value date.timezone "America/New_York"
</IfModule>

]]>
hollyvalero Nov 25, 2015, 07:10 AM https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534791
<![CDATA[Re: Evo 1.0.15 Need to fix Manager/includes/ for Warning: strtotime() for PHP 5.5 upgrade]]> https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534777 set the timezone via .htaccess as well.
TLDR:
<IfModule php5_module>
php_value date.timezone "America/New_York"
</IfModule>

I think you should have hit this problem with PHP 5.3 earlier - or maybe that's using a different php.ini file?

:) KP]]>
kp52 Nov 25, 2015, 04:11 AM https://forums.modx.com/thread/98897/evo-1-0-15-need-to-fix-manager-includes-for-warning-strtotime-for-php-5-5-upgrade#dis-post-534777