Golfreeze.packetlove.com: Life style of Golfreeze Canon400D Family kammtan.com Jazz Freebsd Unix Linux System Admin guitar Music

All about unix linux freebsd and FAQ for Packetlove.com Web hosting , Mail hosting , VoIP + IP PBX server => Trick เกี่ยวกับการแก้ปัญหา เกี่ยวกับ compiler gcc c++ c build make install => Topic started by: golfreeze on มิถุนายน 11, 2012, 12:14:27 PM

Title: แก้ไขปัญหา เบื้องต้นของตัว timezone php5.3
Post by: golfreeze on มิถุนายน 11, 2012, 12:14:27 PM
พอดีอัฟ php ครับแล้วเกิดปัญหา

Warning: date() [function.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 'Asia/Bangkok' for 'ICT/7.0/no DST' instead in apache22

เพิ่มบันทัด timezone เข้าไปใน php code ครับ

<?php

date_default_timezone_set('Asia/Bangkok');

?>