Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Warning: date(): It is not safe to rely on the system's timezone settings.


cclayton

Recommended Posts

Posted

I have recently upgragded my PHP version and now have the following error on my page:

 

Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /var/www/vhosts/domain.co.uk/httpdocs/includes/classes/seo.class.php on line 1776 Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /var/www/vhosts/domain.co.uk/httpdocs/includes/classes/seo.class.php on line 1827 Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /var/www/vhosts/domain.co.uk/httpdocs/includes/classes/seo.class.php on line 1699 Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /var/www/vhosts/domain.co.uk/httpdocs/includes/classes/seo.class.php on line 1827 Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /var/www/vhosts/domain.co.uk/httpdocs/includes/classes/seo.class.php on line 1699 Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /var/www/vhosts/domain.co.uk/httpdocs/includes/classes/seo.class.php on line 1827 Warning: 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 the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /var/www/vhosts/domain.co.uk/httpdocs/includes/classes/seo.class.php on line 1699

 

Can someone tell me what I need to do to remove this error? I am little confused.

 

Many thanks!

Founder & Director at CSC Tours Ltd

Posted

Found the issue, added something similar to this in the file:

 

date_default_timezone_set('America/Los_Angeles');

Founder & Director at CSC Tours Ltd

Posted

If you're in England, you'd probably want your timezone to be 'Europe/London' (see http://php.net/manual/en/timezones.php for the full list). Many servers will let you set up a php.ini file with a command such as

date.timezone = 'Europe/London'

instead of modifying your PHP code. Consult with your web host.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...