Skip to content

Commit

Permalink
mail replyto
Browse files Browse the repository at this point in the history
  • Loading branch information
Paweł Bukowski committed Oct 18, 2013
1 parent d76d008 commit 10eba47
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion modules/Base/Mail/MailCommon_0.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public static function send($to,$subject,$body,$from_addr=null, $from_name=null,
if(!isset($from_name)) $from_name = Variable::get('mail_from_name');
if(!isset($from_addr)) {
$from_addr = Variable::get('mail_from_addr');
if($mail_use_replyto)
if($mail_use_replyto && strpos($mail_use_replyto,'@')!==false)
$mailer->AddReplyTo($mail_use_replyto, $from_name);
$mailer->SetFrom($from_addr, $from_name);
} else {
Expand Down
1 change: 1 addition & 0 deletions modules/Base/Mail/Mail_0.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ public function admin() {

$form->addElement('text','mail_from_name', __('Send e-mails from name'));
$form->addElement('text','mail_use_replyto', __('Set "Reply-To" header'));
$form->addRule('mail_use_replyto', __('Invalid e-mail address'), 'email');

$method = $form->getElement('mail_method')->getSelected();
if($method[0]=='smtp') {
Expand Down

0 comments on commit 10eba47

Please sign in to comment.