Name

MV_MAILFROM — specifies the default sender e-mail address when SMTP is used to send mail

SYNOPSIS

{ user name | e-mail address }

DESCRIPTION

If SMTP is used to send mail from Interchange, this variable specifies the default sender e-mail address.

VARIABLE TYPE

Global variable,
Catalog variable

EXAMPLES

Example: Setting the MV_MAILFROM variable

Add the following to interchange.cfg:

Variable MV_MAILFROM interchange

NOTES

AVAILABILITY

MV_MAILFROM is available in Interchange versions:

4.6.0-5.9.0 (git-head)

SOURCE

Interchange 5.9.0:

Source: lib/Vend/Util.pm
Line 2228 (context shows lines 2218-2232 in send_mail():2106)

last SMTP if $@;
$ok = 0;
$using = "Net::SMTP (mail server $mhost)";
#::logDebug("using $using");
undef $none;

my $smtp = Net::SMTP->new($mhost, Debug => $Global::Variable->{DEBUG}, \
 \
 \
 Hello => $helo) or last SMTP;
#::logDebug("smtp object $smtp");

my $from = $::Variable->{MV_MAILFROM}
|| $Global::Variable->{MV_MAILFROM}
|| $Vend::Cfg->{MailOrderTo};

for(@extra_headers) {
  s/\s*$/\n/;

Source: lib/Vend/Email.pm
Line 288 (context shows lines 278-292 in tag_mime_lite_email():91)

# TO
if (!( $opt->{to} and @{ $opt->{to} } )) {
::logError('mime_lite_email called without the required to= option.');
return;
}

# FROM
if (! $opt->{from} ) {
$opt->{from} =
  $::Variable->{MV_MAILFROM}       ||
  $Global::Variable->{MV_MAILFROM} ||
  $Vend::Cfg->{MailOrderTo};
}
$opt->{from} or do {
  ::logError('Cannot find value for From: header. Make sure ' .

Source: lib/Vend/Email.pm
Line 683 (context shows lines 673-687 in send_mail_legacy():561)

last SMTP if $@;
$ok = 0;
$using = "Net::SMTP (mail server $mhost)";
#::logDebug("using $using");
undef $none;

my $smtp = Net::SMTP->new($mhost, Debug => $Global::Variable->{DEBUG}, Hello => $helo);
#::logDebug("smtp object $smtp");

my $from = $::Variable->{MV_MAILFROM}
|| $Global::Variable->{MV_MAILFROM}
|| $Vend::Cfg->{MailOrderTo};

for(@extra_headers) {
  s/\s*$/\n/;

AUTHORS

Interchange Development Group

SEE ALSO

MailOrderTo(7ic), MV_HELO(7ic), MV_SMTPHOST(7ic)

DocBook! Interchange!