version 1.93, 2003/10/27 19:27:09
|
version 1.95, 2003/11/04 18:37:40
|
Line 149 sub end_foilgroup {
|
Line 149 sub end_foilgroup {
|
my ($target,$token,$tagstack,$parstack,$parser,$safeeval,$style)=@_; |
my ($target,$token,$tagstack,$parstack,$parser,$safeeval,$style)=@_; |
|
|
my $result; |
my $result; |
if ($target eq 'grade' || $target eq 'web' || $target eq 'answer' || $target eq 'tex' || $target eq 'analyze') { |
if ($target eq 'grade' || $target eq 'web' || $target eq 'answer' || |
|
$target eq 'tex' || $target eq 'analyze') { |
my $tex_option_switch=&Apache::lonxml::get_param('texoptions',$parstack,$safeeval); |
my $tex_option_switch=&Apache::lonxml::get_param('texoptions',$parstack,$safeeval); |
my $name; |
my $name; |
my @opt; |
my @opt; |
Line 165 sub end_foilgroup {
|
Line 166 sub end_foilgroup {
|
$result.=&displayanswers($max,$randomize,@opt); |
$result.=&displayanswers($max,$randomize,@opt); |
} elsif ( $target eq 'analyze') { |
} elsif ( $target eq 'analyze') { |
my @shown = &whichfoils($max,$randomize); |
my @shown = &whichfoils($max,$randomize); |
&Apache::response::analyze_store_foilgroup(\@shown,['text','value']); |
&Apache::response::analyze_store_foilgroup(\@shown, |
|
['text','value','location']); |
my $part_id="$Apache::inputtags::part.$Apache::inputtags::response[-1]"; |
my $part_id="$Apache::inputtags::part.$Apache::inputtags::response[-1]"; |
push (@{ $Apache::lonhomework::analyze{"$part_id.options"} },@opt); |
push (@{ $Apache::lonhomework::analyze{"$part_id.options"} },@opt); |
} elsif ( $target eq 'grade') { |
} elsif ( $target eq 'grade') { |
Line 316 sub displayfoils {
|
Line 318 sub displayfoils {
|
} else { |
} else { |
$text=$value.': '.$text; |
$text=$value.': '.$text; |
} |
} |
|
} else { |
|
$text='•'.$text; |
} |
} |
$result.=$text."\n"; |
$result.=$text."\n"; |
} elsif ($target eq 'tex') { |
} elsif ($target eq 'tex') { |
Line 365 sub displayfoils {
|
Line 369 sub displayfoils {
|
my $text=$Apache::response::foilgroup{$name.'.text'}; |
my $text=$Apache::response::foilgroup{$name.'.text'}; |
if (!($text=~s|<drawoptionlist\s*/>|$optionlist|) && $Apache::lonhomework::type ne 'exam') { |
if (!($text=~s|<drawoptionlist\s*/>|$optionlist|) && $Apache::lonhomework::type ne 'exam') { |
$text=$optionlist.$text; |
$text=$optionlist.$text; |
|
} else { |
|
$text='•'.$text; |
} |
} |
$result.=$break.$text."\n"; |
$result.=$break.$text."\n"; |
if ($Apache::lonhomework::type eq 'exam') { |
if ($Apache::lonhomework::type eq 'exam') { |