This is a mobile optimized page that loads fast, if you want to load the real page, click this text.

Помогите пожалуйста с php

Статус
В этой теме нельзя размещать новые ответы.

#Clifford

Мастер
1 Ноя 2020
731
156
111
Имею такие варнинги:
Код:
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. in /home/k/kolyan1h/village-rp.ru/public_html/application/classes/main/index.php on line 10

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 /home/k/kolyan1h/village-rp.ru/public_html/application/classes/main/index.php on line 10

Имею такую строчку кода:
Код:
$date = date('d.m.Y', strtotime('-7 days'));

в .htaccess php_value date.timezone "Europe/Moscow"
 

Inoi

/dev/null
Команда форума
Moderator
VIP
15 Окт 2020
3,804
1,859
208
35
мб твой хостинг не позволяет менять значения таймзоны через .htaccess
можно ебануть
PHP:
date_default_timezone_set("Europe/Moscow");
прямо в скрипт
или если есть доступ к php.ini - указать таймзону там
INI:
date.timezone = "Europe/Moscow"
бывает, что эта настройка вынесена прямо в кп хостера

ну о том, что говорят варнинги вроде пояснять не нужно
 
Реакции: Ximis

#Clifford

Мастер
1 Ноя 2020
731
156
111
Да,помогло,спасибо!
 
Реакции: XDeveluxe
Статус
В этой теме нельзя размещать новые ответы.