2011-12-03 10 views
1

私はcodeignitersメールヘルパー(SMTP)タイムエラーのCodeIgniterでメールのSMTPを送信する - ホスティングのMediaTemple

メールが私の受信トレイに正常に配信されているが、私は、次のエラーが発生します使用して私のウェブサイトからのメール送信をしています:

A PHP Error was encountered 

Severity: Warning 

Message: 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 'America/Los_Angeles' for 'PST/-8.0/no DST' instead 

Filename: libraries/Email.php 

Line Number: 704 

私は最近、私のホスティングをmediatempleに切り替えました。これまでにこのようなメッセージはありませんでした。私はどこか時間帯を指定する必要がありますか?

答えて

2

ファイルにdate.timezoneを設定すると、警告が表示されなくなります。

私は、MediaTempleがあなたのホームディレクトリにphp.iniを含めることによってphp.iniの設定を編集できると信じています。あなたのPHPスクリプト(複数可)に次の行を追加することができます

+0

完璧!ありがとう – hairynuggets

1

あなたはphp.iniのを更新する権限を持っていない場合(通常はそうでない)、
: -

date_default_timezone_set("Asia/Singapore"); <-- replace to your desire city 

以上がありますこの関数のドキュメントはこちらhttp://uk.php.net/date_default_timezone_set

関連する問題