Discussion: mime to http
Afficher un message
Vieux 08/05/2006, 10h03   #3
Francis Galiegue
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: mime to http

Hello,

I do the same thing but using a shell script, and the file is always
inline, anyway in order to obtain the headers I just sent myself a
short mail with a small text part and an attached file, and I could
gather this, which works:

----
cat <<EOF >$MAILFILE
From: root@$MACHINE
To: $RECIPIENTS
Subject: [$MACHINE] - Fichier CSV monitoring - $TODAY
MIME-Version: 1.0
Content-Type: Multipart/Mixed;
boundary="$BOUNDARY"

--$BOUNDARY
Content-Type: text/plain;
charset="us-ascii"
Content-Disposition: inline

En attachement, le fichier CSV de monitoring, jour $TODAY.

--$BOUNDARY
Content-Type: text/csv;
name="monitoring-$TODAY.csv"
Content-Transfer-Encoding: base64
Content-Disposition: attachment;
filename="monitoring-$TODAY.csv"

EOF
----

And then append the MIME-encoded file at the end and send it as is.

HTH!

  Réponse avec citation
 
Page generated in 0,04743 seconds with 9 queries