|Sat 98-02-28 Trevor Astrope <astrope(_at_)tabbweb(_dot_)com> list.procmail
| Hi, I'm really getting tired of receiving messages in html. It seems this
| is the default in MS's Outlook mailer. Can anyone give me pointers to a
| recipe that would bounce html messages back to the sender with a text file
| that included instructions on how they could set Outlook or netscape to
| send in plain text instead of html?
Could you just shut your eyes and let procmail handle these messages
silently? That's what I do. Here is new section from pm-tips.txt page,
Marek's html bounce is also in the page now, but not repeated here.
(see X-info how to get pm-tips.txt)
jari
13.0 Procmail, MIME and HTML
13.1 Software to deal with mime or html
See also nearest Perl CPAN module, http://www.perl.org, site and
CPAN/modules/by-module/MIME/MIME-tools-4.112.tar.gz
There also exists Unix binary `munpack' to explode mime message
to separate files.
13.2 Killing html mime messages
[era] Here is simple filter to throw out unwanted html that is send
by using mime.
:0:
*$ ^Content-Type:$s*multipart/(mixed|alternative);\
$WSPCL*boundary="?\/[^;"]+
* $ B ?? ^--$\MATCH\$([-a-z]+:.*)*Content-type:$s*text/html
junk-html.mbox
Some more examples can be found from section: 'Explaning ^^ and ^'
13.3 Getting rid of unwanted mime attachements (html, vcard)
Microsoft and Netscape MUAs are conquering the PC world and it's likely
that you will receive messages from people that use these software.
The unfortunate thing is that you receive the message in mime format:
HEADERS
--mime-boundary
plain text
--mime-boundary
Some idiotic html (or other type) copy of the text
--mime-boundary
When you would like to see traditional message in format:
HEADERS
plain text
Good news. There is procmail module that addresses this problem. The
module can kill any mime attachement and the predefined sets incule
typical cases:
o Microsoft Explorer has a bad habbit of including 7k
application/ms-tnef attachement to the end of message.
o Lotus Notes sends similar extra attachement.
o Microsoft Express sends a copy of message in html format in the
attachement.
o Netscape's Mozilla sends a copy of message in html. See
example. It Also sends annoying `vcards'
The module is called pm-jamime-kill.rc and included in Jari's
pm-code.shar. See the procmail module section how to get the shar file.
...