Re: use of HTML in AddressModifyCode

2002-05-29 23:30:28
On May 30, 2002 at 01:50, John Belmonte wrote:

Earl Hood wrote:
 > It seems it may be useful to have some kind resource in MHonArc
 > that allows manipulation of addresses in the HTML domain (say

That would be great to have.

What I'd like to set up is to display "user(_at_)(_dot_)(_dot_)(_dot_)" with 
the "..." linking
to a cgi script that displays its encoded query (the full address) using
one of the on-the-fly text to image generators that are around.

Actually, you can replace routine that converts messages headers
to HTML -- complete bypassing the message header layout resources --
with a custom front-end.  For example:

  MAIN: {
    require '' || die qq/ERROR: Unable to require ""\n/;

    $readmail::FormatHeaderFunc = \&my_header_func;
    mhonarc::process_input() ? exit(0) : exit($mhonarc::CODE);

  sub my_header_func {
    my $fields_hash_ref = shift;

The comments about FormatHeaderFunc in are incorrect,
they descibed the old method of invocation before switching to references.
The htmlize_header() function in reflects how the
FormatHeaderFunc is actually called and how MHonArc actually formats
message headers.

It may be worth exposing the function as a configurable resource.