--- loncom/interface/lonparmset.pm 2007/06/19 20:14:31 1.368 +++ loncom/interface/lonparmset.pm 2007/06/20 21:06:51 1.371 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Handler to set parameters for assessments # -# $Id: lonparmset.pm,v 1.368 2007/06/19 20:14:31 albertel Exp $ +# $Id: lonparmset.pm,v 1.371 2007/06/20 21:06:51 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -2047,17 +2047,24 @@ sub crsenv { # # Deal with the emails if ($name =~ /\.email$/) { - my ($user,$domain) = split(/:/,$value); - if (!defined($user) || !defined($domain)) { - $setoutput.= '
'. - &mt("Invalid email address specified, address must be of the form username:domain"). - ''; - undef($value); - } elsif (&Apache::lonnet::homeserver($user,$domain) eq 'no_host') { - $setoutput.= '
'. - &mt("Invalid email address specified, user [_1] is unknown.",$value). - ''; - undef($value); + foreach my $specifier (split(',',$value)) { + my ($user,$sections_or_groups)= + ($specifier=~/^([^\(]+)\(([^\)]+)\)/); + if (!$sections_or_groups) { + $user = $specifier; + } + my ($name,$domain) = split(':',$user); + if (!defined($user) || !defined($domain)) { + $setoutput.= '
'. + &mt("Invalid email address specified, address must be of the form username:domain what was specified was ([_1])",$user). + ''; + undef($value); + } elsif (&Apache::lonnet::homeserver($user,$domain) eq 'no_host') { + $setoutput.= '
'. + &mt("Invalid email address specified, user [_1] is unknown.",$name). + ''; + undef($value); + } } } # Get existing cloners @@ -2226,10 +2233,7 @@ sub crsenv { ' Tabloid [11x17 in], Executive [7 1/2x10 in], A2 [420x594 mm],'. ' A3 [297x420 mm], A4 [210x297 mm], A5 [148x210 mm], A6 [105x148 mm])', 'print_header_format' - => 'Print header format; substitutions: %n student name %c course id %a assignment note, numbers after the % limit the field size', - 'anonymous_quiz' - => ''.&mt('Anonymous quiz/exam').'
'. - ' ('.&mt('yes').' '.&mt('to avoid print students names').' )', + => &mtn(' Print header format; substitutions : %n student name %c course id %a assignment note, numbers after the % limit the field size.').'', 'default_enrollment_start_date' => ''.&mt('Default beginning date for student access.').'', 'default_enrollment_end_date' => ''.&mt('Default ending date for student access.').'', 'nothideprivileged' => ''.&mt('Privileged users that should not be hidden on staff listings').''. @@ -2363,7 +2367,7 @@ $start_header_row $end_header_row $output $end_table - + $end_page ENDENV