0

CodeIgniter 電子メール クラスのメッセージを準備するときに、何か間違ったことをしているようです。私は次のコードを持っています:

$message =  "Registration Confirmation and Receipt";
$message .= "\r\n";
$message .= "Thank you for registering for MAGIC Live. Your credit card receipt and a complete confirmation of your registration is below. Please keep it for your records.\r\n";
$message .= "\r\n";
$message .= "Credit card: XXXX XXXX XXXX ".$group['last4'];
$message .= " Exp: ".$group['exp_month']."/".$group['exp_year']."\r\n";
$message .= "data";
$this->email->message($message);

互いに隣り合った改行文字の 2 つのセットのみが有効であるように見えます。出力されたメールは次のようになります。

Registration Confirmation and Receipt Thank you for registering for MAGIC Live. Your credit card receipt and a complete confirmation of your registration is below. Please keep it for your records.

Credit card: XXXX XXXX XXXX 4242 Exp: 3/2015 data

何かご意見は?

4

1 に答える 1

0

メールの設定を確認してください。改行文字を設定できます。デフォルトは\nです。

$config['newline'] = "\r\n"
于 2012-05-02T03:12:29.017 に答える