version 1.45, 2003/06/24 20:41:56
|
version 1.48, 2004/03/12 18:41:43
|
Line 48 sub start_hintgroup {
|
Line 48 sub start_hintgroup {
|
my $numtries=$Apache::lonhomework::history{"resource.$id.tries"}; |
my $numtries=$Apache::lonhomework::history{"resource.$id.tries"}; |
if ( $numtries eq '') { $numtries = 0; } |
if ( $numtries eq '') { $numtries = 0; } |
my $hinttries=&Apache::lonnet::EXT("resource.$id.hinttries"); |
my $hinttries=&Apache::lonnet::EXT("resource.$id.hinttries"); |
|
if ($ENV{'request.state'} eq 'construct' && |
|
defined($Apache::inputtags::params{'hinttries'})) { |
|
$hinttries=$Apache::inputtags::params{'hinttries'}; |
|
} |
|
|
if ( $hinttries eq '') { $hinttries = 1; } |
if ( $hinttries eq '') { $hinttries = 1; } |
&Apache::lonxml::debug("found :$id:$numtries:$hinttries:"); |
&Apache::lonxml::debug("found :$id:$numtries:$hinttries:"); |
if ( $numtries < $hinttries ) { |
my $gradestatus=$Apache::lonhomework::history{"resource.$id.solved"}; |
|
if ( $numtries < $hinttries || $gradestatus =~ /^correct/) { |
&Apache::lonxml::get_all_text("/hintgroup",$parser); |
&Apache::lonxml::get_all_text("/hintgroup",$parser); |
} |
} |
&Apache::lonxml::startredirection; |
&Apache::lonxml::startredirection; |
Line 144 sub end_numericalhint {
|
Line 150 sub end_numericalhint {
|
} |
} |
$safeeval->share_from('capa',['&caparesponse_capa_check_answer']); |
$safeeval->share_from('capa',['&caparesponse_capa_check_answer']); |
my $name= &Apache::lonxml::get_param('name',$parstack,$safeeval); |
my $name= &Apache::lonxml::get_param('name',$parstack,$safeeval); |
&Apache::response::setup_params('numericalhint'); |
&Apache::response::setup_params('numericalhint',$safeeval); |
my $partid=$Apache::inputtags::part; |
my $partid=$Apache::inputtags::part; |
my $id=$Apache::inputtags::response['-1']; |
my $id=$Apache::inputtags::response['-1']; |
#id submissions occured under |
#id submissions occured under |