0
Ich sende eine Mail mit HTML und Anhang, von sendmail in UNIX. Aber ich bin nicht in der Lage, mehrere Anhänge auf diese Weise hinzuzufügen, mein Ziel ist es, E-Mail mit HTML-Inhalt und Attachment zu senden - aber nicht mehrere Attachment hier hinzufügen.mehrere Anhänge in sendmail -UNIX
mail_msg2()
{
DIR="/home/input"
SENDING_FILE_NAME="ExportData.xls"
v_mailpart="$(uuidgen)/$(hostname)"
echo "From: [email protected]
To: [email protected]
Cc: [email protected]
Subject: $SubjectData
Content-Type: multipart/mixed; boundary=\"$v_mailpart\"
MIME-Version: 1.0
This is a multi-part message in MIME format.
--$v_mailpart
Content-Type: text/html
$Body
--$v_mailpart
Content-Transfer-Encoding: base64
Content-Type: application/xlsx; name=$SENDING_FILE_NAME
Content-Disposition: attachment; filename=$SENDING_FILE_NAME
`base64 $DIR/$SENDING_FILE_NAME`
--$v_mailpart--" | /usr/sbin/sendmail -t
}
Körper = cat $path/output/output.html