joel
joel

Reputation: 125

cakephp : Getting error on first run

I just copied all cakephp file to my localhost (I am using latest XAMPP), when I run cake I am getting a bunch of warnings like

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 'Asia/Calcutta' for '5.5/no DST' instead in D:\xampp\htdocs\cake\cake1\cake\libs\cache.php on line 448

What is this and how can I fix it ?

Thanks a lot guys

Upvotes: 1

Views: 162

Answers (2)

deceze
deceze

Reputation: 521995

/app/config/core.php:

/**
 * If you are on PHP 5.3 uncomment this line and correct your server timezone
 * to fix the date & time related errors.
 */
    //date_default_timezone_set('UTC');

You are required to set this since the behavior of time related functions changed in PHP 5.3.

Upvotes: 3

thirtydot
thirtydot

Reputation: 228152

In D:\xampp\php\php.ini you need to set the date.timezone setting.

Upvotes: 0

Related Questions