I have been using mutt to send emails from inside another application & it works fine. I have to send html files and currently I have to send them as attachments. So I use
mutt -s "hi" -a attach.html [email protected] < /dev/null
But if I try to send the html file as the body as follows
mutt -e content_type=text/html Email address -s "subject" < test.html
then instead of the html file i get the source text of the html file.
Is there any way that I can make the body of the message as html instead of plain text???
When I try your command, mutt is telling me that content_type=text/html
is an unknown command. So you have to use the "set" command to make this work:
mutt -e "set content_type=text/html" Email address -s "subject" < test.html
That worked in my tests.
I tried with mutt 1.6d and that option -e "set content_type=text/html" doesn't work for me. After search around i found below command line works for me:
mutt -e "my_hdr Content-Type: text/html" [email protected] -s "subject" < mytest.html
Reference here
LinuxQuestions
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With