in reply to Matching non-words

Hi,

As I understand your question, the thing between() can be an email address. And in that case, you want to trigger something. If I am completely wrong, well, I 'll need a coffee.

You can use Email::Valid to check the contents between the braces and trigger it it is true, f.e.

use strict; use Email::Valid; my $subject="Subject: You've Won a Million Dollars!!!(xstebxz)" if ( $subject =~ /(\(.*\))$/ ) { if ( Email::Valid->address( -address => $1, -mxcheck => 0, )) { print "Subject contains email address"; } }
I hope this helps,
---------------------------
Dr. Mark Ceulemans
Senior Consultant
IT Masters, Belgium