[vhffs-dev] [svn] commit: r159 - /trunk/vhffs-listengine/src/listengine.pl |
[ Thread Index |
Date Index
| More vhffs.org/vhffs-dev Archives
]
Author: jd
Date: Thu Feb 16 13:46:19 2006
New Revision: 159
Log:
add + and . to regexp
modify others regexp
Modified:
trunk/vhffs-listengine/src/listengine.pl
Modified: trunk/vhffs-listengine/src/listengine.pl
==============================================================================
--- trunk/vhffs-listengine/src/listengine.pl (original)
+++ trunk/vhffs-listengine/src/listengine.pl Thu Feb 16 13:46:19 2006
@@ -141,7 +141,7 @@
my $header;
my $email;
my ( $message_id )= ($mail->get( 'Message-Id' ) =~ /<(.+)>/);
- my ( $from ) = ( $mail->get('From') =~ /(([a-zA-Z_\-0-9^\s]+)@([a-zA-Z_\-0-9^\s]+)\.(\w+))/);
+ my ( $from ) = ( $mail->get('From') =~ /(([\+\.a-zA-Z_\-0-9^\s]+)@([\.a-zA-Z_\-0-9^\s]+)\.(\w+))/);
my $directory = get_moderation_dir( $list );
my $subject = $mail->get('Subject');
@@ -443,7 +443,7 @@
exit -1 if( ! defined $list );
exit 0 if( $list->fetch < 0 );
- my ( $from ) = ( $mail->get('From') =~ /(([a-zA-Z_\-0-9^\s]+)@([a-zA-Z_\-0-9^\s]+)\.(\w+))/);
+ my ( $from ) = ( $mail->get('From') =~ /(([\+\.a-zA-Z_\-0-9^\s]+)@([a\.-zA-Z_\-0-9^\s]+)\.(\w+))/);
my $subject = $mail->get('Subject');
my $subs = $list->get_members;
@@ -594,7 +594,7 @@
my $mail = shift;
my $list = shift;
- my ( $from ) = ( $mail->get('From') =~ /.*<(.+\@.+)>/);
+ my ( $from ) = ( $mail->get('From') =~ /(([\+\.a-zA-Z_\-0-9^\s]+)@([\.a-zA-Z_\-0-9^\s]+)\.(\w+))/);
my $subject = $mail->get('Subject');
my $action;
my $hash;
@@ -858,7 +858,7 @@
sub get_lang
{
my $mail = shift;
- my ( $from ) = ( $mail->get('From') =~ /.*<(.+\@.+)>/);
+ my ( $from ) = ( $mail->get('From') =~ /(([\+\.a-zA-Z_\-0-9^\s]+)@([\.a-zA-Z_\-0-9^\s]+)\.(\w+))/);
my $lang = Vhffs::Services::Mailing::get_lang_for_sub( $vhffs , $from );
if( defined $lang )