Error Date.timezone Pada CodeIgniter
Pesan Kesalahan:
A PHP Error was encountered
Severity: Warning
Message: 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.
Solusi 1:
.httacces tambahkan
php_value date.timezone Asia/Jakarta
Solusi 2:
set date_default_timezone_set(‘Asia/Jakarta’); pada index.php utama code igniter
File index.php yang perlu diubah adalah file index.php yang berada sejajar dengan folder root
Edit index.php tersebut, kemudian tambahkan line berikut :
date_default_timezone_set(‘Asia/Jakarta’);
Tidak ada komentar: