http://www.luckyshotphotos.com/index.php
Zenphoto and Zenpage? Or ... ya... Error:
Strict Standards: strtotime() [function.strtotime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable 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 'America/Denver' for 'MST/-7.0/no DST' instead in /home/***/public_html/zp-core/plugins/zenpage/zenpage-template-functions.php on line 810
Strict Standards: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable 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 'America/Denver' for 'MST/-7.0/no DST' instead in /home/***/public_html/zp-core/functions.php on line 267
If you would, please add the following code to the end of functions-basic.php:
if (function_exists('date_default_timezone_set')) { date_default_timezone_set(date_default_timezone_get()); }
Leave the error reporting as it was in the release. Let us know the result
Okay, I have nightly 3043
I added the code to the end of functions basic
`
Strict Standards: date_default_timezone_get() [function.date-default-timezone-get]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable 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 'America/Denver' for 'MST/-7.0/no DST' instead in /home/**/public_html/zp-core/functions-basic.php on line 819
Warning: Cannot modify header information - headers already sent by (output started at /home//public_html/zp-core/functions-basic.php:819) in /home//public_html/index.php on line 25
Warning: Cannot modify header information - headers already sent by (output started at /home//public_html/zp-core/functions-basic.php:819) in /home//public_html/zp-core/functions.php on line 1913
Warning: Cannot modify header information - headers already sent by (output started at /home//public_html/zp-core/functions-basic.php:819) in /home//public_html/index.php on line 100
Warning: Cannot modify header information - headers already sent by (output started at /home//public_html/zp-core/functions-basic.php:819) in /home//public_html/index.php on line 101
`
Hi guys,
I use the last nightly version of zenphoto - 1.2.2 [3048], this is a fresh install and I get hardly the same error :
Strict Standards: date() [function.date]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable 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 'America/Chicago' for 'CST/-6,0/no DST' instead in /home/user/zenphoto/zp-core/class-album.php on line 279
Warning: Cannot modify header information - headers already sent by (output started at /home/user/zenphoto/zp-core/class-album.php:279) in /home/user/zenphoto/zp-core/admin-edit.php on line 300
Please post your PHP version if you are having this problem. The above code is "supposed" to fix the issue according to the PHP document. However, at least for some it does not.
To suppress the message change line 84 of functions-basic.php to:
error_reporting(E_ALL ^E_NOTICE);
Hi Stephen,
I use PHP Version 4.4.6.
I added to the end of functions-basic.php just before ?>:
if (function_exists('date_default_timezone_set')) { date_default_timezone_set(date_default_timezone_get()); }
here is what I get :
`
Strict Standards: date_default_timezone_get() [function.date-default-timezone-get]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable 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 'America/Chicago' for 'CST/-6.0/no DST' instead in /home/user/zenphoto/zp-core/functions-basic.php on line 819
Warning: Cannot modify header information - headers already sent by (output started at /home/user/zenphoto/zp-core/functions-basic.php:819) in /home/user/zenphoto/zp-core/functions.php on line 1913
Warning: Cannot modify header information - headers already sent by (output started at /home/user/zenphoto/zp-core/functions-basic.php:819) in /home/user/zenphoto/index.php on line 25
Warning: Cannot modify header information - headers already sent by (output started at /home/user/zenphoto/zp-core/functions-basic.php:819) in /home/user/zenphoto/index.php on line 100
Warning: Cannot modify header information - headers already sent by (output started at /home/user/zenphoto/zp-core/functions-basic.php:819) in /home/user/zenphoto/index.php on line 101
`
Well, this is interesting. The documentation says that this error message starts with version 5.1.0. For you, I guess you will just have to change the error reporting as described above. The date_default_timezone are not available until PHP 5.0.
Your other option, if you don't mind trying, is to change the date.timezone setting in your PHP.ini file. Or add to the end of functions.php ini_set('date.timezone', 'UTC'); (You can substitute your local timezone from the list shown here: http://us.php.net/manual/en/timezones.php)
I just updated after a few weeks and saw the same behaviour. Adding
ini_set('date.timezone', 'Europe/Dublin');
to the end of functions.php seems to fix the problem for now (i.e. prevent the messages), but I'll sync up with whatever the eventual outcome is. I'm using a host based in the US so should I be referring to the timezone where the server is physically located instead?
Okay well I changed the error reporting, I dont get the time zone but i still get:
`
Warning: Cannot modify header information - headers already sent by (output started at /home/--/public_html/zp-core/functions-basic.php:1) in /home/--/public_html/index.php on line 25
Warning: Cannot modify header information - headers already sent by (output started at /home/--/public_html/zp-core/functions-basic.php:1) in /home/--/public_html/zp-core/functions.php on line 1913
Warning: Cannot modify header information - headers already sent by (output started at /home/--/public_html/zp-core/functions-basic.php:1) in /home/--/public_html/index.php on line 100
Warning: Cannot modify header information - headers already sent by (output started at /home/--/public_html/zp-core/functions-basic.php:1) in /home/--/public_html/index.php on line 101
`
To all having this issue. I have released a version of functions-basic.php with the change to try to set the timezone. Try that version. If it does not work, then use the error report supression--change line 84 of functions-basic.php to:
error_reporting(E_ALL ^E_NOTICE);
But also report the success/failure and your PHP version.
Okay, my website got spammed lol! (Comments) okay so... It seems that the update worked (3052). I have no errors at all...
Okay question, off topic... I got some comments on a album, but I think they are disabled, I cant view/post a comment on a album (not a image), yet I see them under "recent comments"
Well, the actual comment post handling is done by the controller. Right now it does not look at the comment enable option. Long story, but that started out as a theme based option. I suppose that we can now not process comments if the option is disabled.
Anyway, as things are now, a spammer familiar with zenphoto can post a comment even though you have them disabled. Suggest you enable Captcha. that will put a wrinkle on the spammers.