--- loncom/interface/lonpreferences.pm 2010/01/05 22:54:46 1.179.2.2
+++ loncom/interface/lonpreferences.pm 2010/09/19 14:22:40 1.179.2.4
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Preferences
#
-# $Id: lonpreferences.pm,v 1.179.2.2 2010/01/05 22:54:46 raeburn Exp $
+# $Id: lonpreferences.pm,v 1.179.2.4 2010/09/19 14:22:40 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -995,16 +995,21 @@ sub verify_and_change_msgforward {
my $domain = $env{'user.domain'};
my $newscreen = '';
my $message='';
- foreach (split(/\,/,$env{'form.msgforward'})) {
- my ($msuser,$msdomain)=split(/[\@\:]/,$_);
+ foreach my $recip (split(/\,/,$env{'form.msgforward'})) {
+ my ($msuser,$msdomain);
+ if ($recip =~ /:/) {
+ ($msuser,$msdomain)=split(':',$recip);
+ } else {
+ ($msuser,$msdomain)=split(/\@/,$recip);
+ }
$msuser = &LONCAPA::clean_username($msuser);
$msdomain = &LONCAPA::clean_domain($msdomain);
if (($msuser) && ($msdomain)) {
- if (&Apache::lonnet::homeserver($msuser,$msdomain) ne 'no_host') {
- $newscreen.=$msuser.':'.$msdomain.',';
- } else {
- $message.= &mt('No such user: ').''.$msuser.':'.$msdomain.'
';
- }
+ if (&Apache::lonnet::homeserver($msuser,$msdomain) ne 'no_host') {
+ $newscreen.=$msuser.':'.$msdomain.',';
+ } else {
+ $message.= &mt('No such user: ').''.$msuser.':'.$msdomain.'
';
+ }
}
}
$newscreen=~s/\,$//;
@@ -1378,7 +1383,7 @@ sub client_form {
.&Apache::lonhtmlcommon::row_closure()
.&Apache::lonhtmlcommon::row_title(
'')
- .''
+ .''
.''
.&Apache::lonhtmlcommon::row_closure()
.&Apache::lonhtmlcommon::row_title(