--- loncom/interface/courseprefs.pm 2023/06/03 03:32:16 1.123 +++ loncom/interface/courseprefs.pm 2023/06/03 11:21:37 1.124 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Handler to set configuration settings for a course # -# $Id: courseprefs.pm,v 1.123 2023/06/03 03:32:16 raeburn Exp $ +# $Id: courseprefs.pm,v 1.124 2023/06/03 11:21:37 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -316,7 +316,7 @@ sub handler { idnu => 'Course ID or number', unco => 'Unique code', desc => 'Course Description', - cred => 'Student credits', + cred => 'Student credits', ownr => 'Course Owner', cown => 'Course Co-owners', catg => 'Categorize course', @@ -522,7 +522,7 @@ sub handler { uselcmath => 'Student formula entry uses inline preview, not DragMath pop-up', usejsme => 'Molecule editor uses JSME (HTML5) in place of JME (Java)', inline_chem => 'Chemical reaction response uses inline preview, not pop-up', - extresource => 'Display of external resources', + extresource => 'Display of external resources', }, }, 'grading' => @@ -1337,14 +1337,14 @@ sub process_changes { my ($classorder,$classtitles) = &discussion_vote_classes(); my $fontchange = 0; foreach my $class (@{$classorder}) { - my $ext_entry = $entry.'_'.$class; + my $ext_entry = $entry.'_'.$class; my $size = $env{'form.'.$ext_entry.'_size'}; my $unit = $env{'form.'.$ext_entry.'_unit'}; my $weight = $env{'form.'.$ext_entry.'_weight'}; my $style = $env{'form.'.$ext_entry.'_style'}; my $other = $env{'form.'.$ext_entry.'_other'}; $size =~ s/,//g; - $unit =~ s/,//g; + $unit =~ s/,//g; $weight =~ s/,//g; $style =~ s/,//g; $other =~ s/[^\w;:\s\-\%.]//g; @@ -1352,7 +1352,7 @@ sub process_changes { $newvalues{$ext_entry} = join(',',($size.$unit,$weight,$style,$other)); my $current = $values->{$ext_entry}; if ($values->{$ext_entry} eq '') { - $current = ',,,'; + $current = ',,,'; } if ($newvalues{$ext_entry} ne $current) { $changes->{$ext_entry} = $newvalues{$ext_entry}; @@ -1361,7 +1361,7 @@ sub process_changes { } if ($fontchange) { $changes->{$entry} = 1; - } + } } elsif ($entry eq 'nothideprivileged') { my @curr_nothide; my @new_nothide; @@ -1436,7 +1436,7 @@ sub process_changes { my $newtext = $maxnum-1; $newhdr[$env{'form.printfmthdr_pos_'.$newtext}] = $env{'form.printfmthdr_text_'.$newtext}; $newvalues{$entry} = join('',@newhdr); - } elsif (($entry eq 'languages') || + } elsif (($entry eq 'languages') || ($entry eq 'checkforpriv')) { my $settings; my $total = $env{'form.'.$entry.'_total'}; @@ -1452,7 +1452,7 @@ sub process_changes { } if ($env{'form.'.$entry.'_'.$total} ne '') { my $new = $env{'form.'.$entry.'_'.$total}; - if ($entry eq 'languages') { + if ($entry eq 'languages') { my %langchoices = &get_lang_choices(); if ($langchoices{$new}) { $settings .= $new; @@ -1551,7 +1551,7 @@ sub process_changes { } else { $newvalues{$entry} = $env{'form.'.$entry}; } - unless (($entry eq 'co-owners') || ($entry eq 'discussion_post_fonts') || + unless (($entry eq 'co-owners') || ($entry eq 'discussion_post_fonts') || ($entry eq 'extresource') || ($entry eq 'timezone')) { if ($newvalues{$entry} ne $values->{$entry}) { $changes->{$entry} = $newvalues{$entry}; @@ -1797,7 +1797,7 @@ sub get_linkprot_id { $tries ++; sleep (0.1); if ($context eq 'domain') { - $gotlock = &Apache::lonnet::newput_dom('linkprot',$lockhash,$cdom); + $gotlock = &Apache::lonnet::newput_dom('linkprot',$lockhash,$cdom); } else { $gotlock = &Apache::lonnet::newput('lti',$lockhash,$cdom,$cnum); } @@ -1835,7 +1835,7 @@ sub get_linkprot_id { $error = 'nonumber'; } } - my $dellockoutcome; + my $dellockoutcome; if ($context eq 'domain') { $dellockoutcome = &Apache::lonnet::del_dom('linkprot',['lock'],$cdom); } else { @@ -3123,7 +3123,7 @@ sub store_linkprot { } } elsif ($title eq 'returnurl') { if ($values{$title}) { - $display .= &mt('Return URL parameter').': '.$values{$title}.', '; + $display .= &mt('Return URL parameter').': '.$values{$title}.', '; } } elsif ($title eq 'passbackformat') { if ($values{$title} eq '1.0') { @@ -3555,7 +3555,7 @@ sub get_jscript { $local_to_standard{$code_order[$i]} = $standardnames[$i]; } foreach my $cloner (@cloners) { - if (($cloner !~ /^\Q*:\E$match_domain$/) && + if (($cloner !~ /^\Q*:\E$match_domain$/) && ($cloner !~ /^$match_username\:$match_domain$/)) { foreach my $item (split(/\&/,$cloner)) { my ($key,$val) = split(/\=/,$item); @@ -3782,7 +3782,7 @@ function toggleTimeZone() { } ENDSCRIPT $jscript = '