Adding Boilerplate (was Re: [Mimedefang] HTML mails problem)

David F. Skoll dfs at roaringpenguin.com
Thu May 23 09:10:03 EDT 2002


pA tutorial on adding boilerplate:

> $Boilerplate = "
> http://www.patni.com
> World-Wide Partnerships. World-Class Solutions.
>
> This e-mail message may contain proprietary, confidential or legally
> ... 10 lines of legalese deleted...
> please notify us immediately at $Email and delete this mail.";

First of all, this kind of boilerplate is really annoying and probably
useless.  If I receive an e-mail, I believe I can do whatever I like
with it short of violating copyright law.  In particular, I archive
every piece of e-mail I receive, and I do not delete anything,
regardless of any disclaimers.  Instead of adding a dozen lines to
e-mail messages, at least just put a link to the e-mail "terms of
use".

That being said:  If all you want to do is add boilerplate, this is the
proper way to do it:

# Filter does nothing
sub filter {
	return action_accept();
}

# filter_end adds boilerplate
sub filter_end {
    my($entity) = @_;
    # You need a plain-text version:
    append_text_boilerplate($entity, "----------\nPlain-Text Disclaimer\n", 0);

    # And also an HTML version:
    append_html_boilerplate($entity, "<hr>\n<b>HTML</b> Disclaimer\b", 0);
}

The upcoming MIMEDefang 2.12-BETA-4 release will fix the problem of
message duplication for mixed text/plain and text/html messages.

Regards,

David.




More information about the MIMEDefang mailing list