Mail::setReplyTo
Reply-Toのアドレスを追加します
説明
public self Mail::setReplyTo( string $address, [ string $name = null ] )
呼び出すたびに、Reply-Toのアドレスを1つずつ追加します。削除するときはMail::clearReplyToを使います。
引数
| 名前 | データ型 | デフォルト | 備考 |
|---|---|---|---|
| $address | string | Reply-Toのアドレス | |
| $name | string | null | Reply-Toの名前 |
例
Controller
use Fegg\Tool\Mail;
$mail = new Mail('Mail subject', 'Mail body');
$mail->setReplyTo($this->in('mail'), $this->in('name'));
$mail->send('admin@example.com', 'Contact form', 'noreply@example.com');