How to resend emails that have HTML?
How to resend emails that have HTML?
am 11.01.2006 16:14:19 von kj
I have a Unix account that I use exclusively for "text work" (i.e.
no X), and I use emacs RMAIL to read my mail, mostly because I've
used forever. One problem is that an increasing fraction of the
email that arrives at this account has embedded HTML. Such emails
are displayed fine by the mail reader (gmail) I use with my other
(graphics-enabled) account, but if I re-send them from RMAIL (C-u
f) to this account, then the HTML is no longer recognized, and the
display just shows the raw HTML. Same thing happens if I forward
the mail (instead of resending it).
I imagine that there are Unix mailers out there that can handle
this problem easily, but I want to know how to solve this problem
using only tools like Perl, bash scripts, and/or mail(1).
The naive approach of
mail recipient@host < /path/to/spool/message_file
had the same problems as RMAIL's C-u f approach.
How must I modify the spooled message file before the above command
so that the receiving program understands the HTML?
Likewise, how must I modify an HTML-bearing message being forwarded
via RMAIL to achieve the same purpose.
Thanks!
kj
--
NOTE: In my address everything before the first period is backwards;
and the last period, and everything after it, should be discarded.
Re: How to resend emails that have HTML?
am 11.01.2006 16:27:38 von Peter Peters
On Wed, 11 Jan 2006 15:14:19 +0000 (UTC), kj
wrote:
>I have a Unix account that I use exclusively for "text work" (i.e.
>no X), and I use emacs RMAIL to read my mail, mostly because I've
>used forever. One problem is that an increasing fraction of the
>email that arrives at this account has embedded HTML. Such emails
>are displayed fine by the mail reader (gmail) I use with my other
>(graphics-enabled) account, but if I re-send them from RMAIL (C-u
>f) to this account, then the HTML is no longer recognized, and the
>display just shows the raw HTML. Same thing happens if I forward
>the mail (instead of resending it).
I don't know rmail but most unix text mailers I know have the option to
bounce the e-mail to another address. This normally leaves everything
including MIME attachments intact.
--
Peter Peters, senior netwerkbeheerder
Dienst Informatietechnologie, Bibliotheek en Educatie (ITBE)
Universiteit Twente, Postbus 217, 7500 AE Enschede
telefoon: 053 - 489 2301, fax: 053 - 489 2383, http://www.utwente.nl/itbe
Re: How to resend emails that have HTML?
am 14.01.2006 11:05:52 von Kari Hurtta
kj writes:
> I have a Unix account that I use exclusively for "text work" (i.e.
> no X), and I use emacs RMAIL to read my mail, mostly because I've
> used forever. One problem is that an increasing fraction of the
> email that arrives at this account has embedded HTML. Such emails
> are displayed fine by the mail reader (gmail) I use with my other
> (graphics-enabled) account, but if I re-send them from RMAIL (C-u
> f) to this account, then the HTML is no longer recognized, and the
> display just shows the raw HTML. Same thing happens if I forward
> the mail (instead of resending it).
>
> I imagine that there are Unix mailers out there that can handle
> this problem easily, but I want to know how to solve this problem
> using only tools like Perl, bash scripts, and/or mail(1).
>
> The naive approach of
>
> mail recipient@host < /path/to/spool/message_file
>
> had the same problems as RMAIL's C-u f approach.
How about
/usr/sbin/sendmail -oi recipient@host < /path/to/spool/message_file
(may be /usr/lib/sendmail )
sendmail expects to get mail including all headers from standard input.
-oi disables (if enabled) detection of . as end of mail.
This usage is usually regognized even when actual program is not the Sendmail
(most unix MTAs provide that sendmail -calling convention.)
> How must I modify the spooled message file before the above command
> so that the receiving program understands the HTML?
>
> Likewise, how must I modify an HTML-bearing message being forwarded
> via RMAIL to achieve the same purpose.
/ Kari Hurtta