version 1.208, 2007/02/18 02:03:18
|
version 1.209, 2007/03/01 02:31:29
|
Line 601 sub end_numericalresponse {
|
Line 601 sub end_numericalresponse {
|
} |
} |
} |
} |
} |
} |
|
&setup_prior_tries_hash(); |
} elsif ($target eq 'edit') { |
} elsif ($target eq 'edit') { |
$result.='</td></tr>'.&Apache::edit::end_table; |
$result.='</td></tr>'.&Apache::edit::end_table; |
} elsif ($target eq 'answer' || $target eq 'analyze') { |
} elsif ($target eq 'answer' || $target eq 'analyze') { |
Line 791 sub end_numericalresponse {
|
Line 792 sub end_numericalresponse {
|
return $result; |
return $result; |
} |
} |
|
|
|
sub setup_prior_tries_hash { |
|
#FIXME support multi answer numericals/formula |
|
my $part=$Apache::inputtags::part; |
|
my $id=$Apache::inputtags::response[-1]; |
|
foreach my $i (1..$Apache::lonhomework::history{'version'}) { |
|
my $key = "$i:resource.$part.$id.submission"; |
|
next if (!exists($Apache::lonhomework::history{"$key"})); |
|
$Apache::inputtags::submission_display{$key} = |
|
'<pre>'.&HTML::Entities::encode($Apache::lonhomework::history{$key}, |
|
'"<>&').'</pre>'; |
|
} |
|
} |
|
|
sub check_for_answer_errors { |
sub check_for_answer_errors { |
my ($parstack,$safeeval) = @_; |
my ($parstack,$safeeval) = @_; |
&add_in_tag_answer($parstack,$safeeval); |
&add_in_tag_answer($parstack,$safeeval); |