version 1.252, 2012/03/05 11:50:39
|
version 1.255, 2014/12/30 20:03:15
|
Line 1
|
Line 1
|
# The LearningOnline Network with CAPA |
# The LearningOnline Network with CAPA |
# caparesponse definition |
# caparesponse definition |
# |
# |
# caparesponse.pm,v 1.249.8.2 2012/02/04 20:40:15 foxr |
# $Id$ |
# |
# |
# Copyright Michigan State University Board of Trustees |
# Copyright Michigan State University Board of Trustees |
# |
# |
Line 456 sub check_submission {
|
Line 456 sub check_submission {
|
my ($result,@msgs) = |
my ($result,@msgs) = |
&Apache::run::run("&caparesponse_check_list()",$safeeval); |
&Apache::run::run("&caparesponse_check_list()",$safeeval); |
&Apache::lonxml::debug("checking $name $result with $response took ".&Time::HiRes::tv_interval($t0)); |
&Apache::lonxml::debug("checking $name $result with $response took ".&Time::HiRes::tv_interval($t0)); |
|
|
&Apache::lonxml::debug('msgs are '.join(':',@msgs)); |
&Apache::lonxml::debug('msgs are '.join(':',@msgs)); |
my ($awards)=split(/:/,$result); |
my ($awards)=split(/:/,$result); |
my @awards= split(/,/,$awards); |
my @awards= split(/,/,$awards); |
Line 646 sub end_numericalresponse {
|
Line 645 sub end_numericalresponse {
|
if (($target eq 'web') && ($tag eq 'formularesponse') |
if (($target eq 'web') && ($tag eq 'formularesponse') |
&& ($Apache::lonhomework::type ne 'exam') && ($Apache::inputtags::status['-1'] eq 'CAN_ANSWER') |
&& ($Apache::lonhomework::type ne 'exam') && ($Apache::inputtags::status['-1'] eq 'CAN_ANSWER') |
&& (&Apache::lonnet::EXT('resource.'.$partid.'_'.$id.'.turnoffeditor') ne 'yes')) { |
&& (&Apache::lonnet::EXT('resource.'.$partid.'_'.$id.'.turnoffeditor') ne 'yes')) { |
$result.=&Apache::response::edit_mathresponse_button($id,"HWVAL_$id"); |
$result.=&Apache::response::edit_mathresponse_button($partid,$id); |
} |
} |
|
|
&Apache::response::setup_prior_tries_hash(\&format_prior_response_numerical); |
&Apache::response::setup_prior_tries_hash(\&format_prior_response_numerical); |