procmail
[Top] [All Lists]

Re: matching on ^TO_() not working

2000-07-11 10:40:13
Is there a ^TO_() macro?  Looking through the manuals I can't find one.

%> man procmail procmailrc procmailex | grep TO

Or is this a new feature?  If not, I'm assuming that you're mistaking
'^TO_()' with '^TO_'.


On Mon, 10 Jul 2000, Jerry Preeper wrote:

I have a recipe using the ^TO_() macro but it's not catching any of the
emails it should be... It seems that in most of the emails I want to catch,
the only place I'm finding the email address it should match on is in a
Received header.  However, in others it's not appearing in any header at
all, which is really weird.   Has anyone run into this problem and have any
idea on how to catch these... 

Also, is there any way to create a value for the to address it matched on
so I can insert that address in my mysql table too... 

here is the current recipe I'm using

:0
* ^TO_()(_dot_)*editor(_at_)cts(_dot_)com
{
 SUBJECT=`formail -zxSubject`
 BODY=`formail -I ""`

 :0bc:
 | /www/cgi-bin/parse_editor_mail.cgi "$SUBJECT" "$BODY"
}

I tried changing the recipe to this to catch the address it's going to 

:0
* ^TO_()(_dot_)*editor(_at_)cts(_dot_)com
{
 TO=$MATCH
 SUBJECT=`formail -zxSubject`
 BODY=`formail -I ""`

 :0bc:
 | /www/cgi-bin/parse_editor_mail.cgi "$SUBJECT" "$BODY" "$TO"
}

and adjusting the perl script for the insert, but that didn't work either.
Thanks for any help someone can provide.

Jerry



_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail



_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>