LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Send HTML mail via command line interface (https://www.linuxquestions.org/questions/linux-general-1/send-html-mail-via-command-line-interface-378744/)

xlash 10-31-2005 05:25 PM

Send HTML mail via command line interface
 
Hello,
I'm trying to send an HTML email, including JPEGS in it from command line.

I'm running a batch job which needs wo send periodically emails with the newest stats jpeg. Anybody knows how?

I can't find anything in the sendmail, mail/nail manual either.
P.S.: in the HTML document, does the img tag needs to refer to www, or it can refer to embedded jpegs? (If yes, how?)

Thanks,

bathory 11-02-2005 03:16 AM

Use mutt:
Code:

mutt -s "subject" -a image1.jpg -a image2.jpg -a page.html recipient@domain.com < /dev/null
You must use the -a option for any attached image, or html page

xlash 11-02-2005 01:02 PM

Thanks for suggesting an MIME email client.

However, I'm unable to send HTML ContentType.

With the -a options, it simply attach the file.

With the -i, it simply read the ASCII data into the file.

put as <, it display the ASCII.

I've try sending that mail first to myself@localhost, so I can check if the header for section 1 is correct, but it is not.

Any ideas?

Tx


All times are GMT -5. The time now is 11:33 PM.