Gunnar Hjalmarsson wrote:
Jeroen FF Heijmans wrote:
I want to strip the signature (from "-- " till the end) from the
messages. How can this be done?
By using custom filters. For instance, to strip things from plain text
messages, this is what you should do:
- Copy mhtxtplain.pl to for instance my-txtplain.pl
- Add a regular expression to my-txtplain.pl that does what you want.
Something like:
$$data =~ s/^-- \r?\n[\s\S]*//m;
- Tell MHonArc to use my-txtplain.pl instead of mhtxtplain.pl, when
filtering messages, by setting the <MIMEFilters> resource in the
resource file.
More guidance at
http://www.mhonarc.org/MHonArc/doc/resources/mimefilters.html
Gunnar thanks for your quick response.
I've done it all.
I made a copy of mhtxtplain.pl to my-txtplain.pl with the same user:group
and permissions.
I added your line in front of the first $$data tag:
(this one)
# <CR><LF> => <LF> to make parsing easier
$$data =~ s/\r\n/\n/g;
I added next lines as first ones in my blog.mrc (from the site):
<MIMEFilters>
application/x-patch; m2h_text_plain::filter; my-txtplain.pl
message/delivery-status; m2h_text_plain::filter; my-txtplain.pl
message/partial; m2h_text_plain::filter; my-txtplain.pl
text/*; m2h_text_plain::filter; my-txtplain.pl
text/plain; m2h_text_plain::filter; my-txtplain.pl
x-sun-attachment; m2h_text_plain::filter; my-txtplain.pl
</MIMEFilters>
But still the signatures stay in de posts.
I'm I doing stuff on the wrong lines ?
I'm not sure what I must do next (next to reading the site)
--
Grtz,
Jeroen "FF" Heijmans
---------------------------------------------------------------------
To sign-off this list, send email to majordomo(_at_)mhonarc(_dot_)org with the
message text UNSUBSCRIBE MHONARC-USERS