--- loncom/homework/structuretags.pm 2010/12/31 19:24:48 1.465.2.9
+++ loncom/homework/structuretags.pm 2010/12/31 02:40:14 1.483
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# definition of tags that give a structure to a document
#
-# $Id: structuretags.pm,v 1.465.2.9 2010/12/31 19:24:48 raeburn Exp $
+# $Id: structuretags.pm,v 1.483 2010/12/31 02:40:14 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -176,7 +176,7 @@ function file_deletion_check(formname) {
}
var str = new RegExp("^HWFILE.+_delete\$");
var delboxes = new Array();
- for (i=0; i'."\n";
}
- foreach my $field ('questiontype','rndseed') {
+ foreach my $field ('trial','questiontype') {
if ($env{"form.grade_$field"} ne '') {
$result .= ''."\n";
}
}
-
}
} elsif ($target eq 'tex') {
$result .= 'INSERTTEXFRONTMATTERHERE';
@@ -1341,6 +1326,9 @@ sub end_problem {
}
}
}
+ if ($target eq 'web') {
+ $result.=&Apache::functionplotresponse::init_script();
+ }
if ($target eq 'grade') {
&Apache::lonhomework::showhash(%Apache::lonhomework::results);
&finalize_storage();
@@ -1842,6 +1830,7 @@ sub ordered_show_check {
return $in_order_show;
}
+
sub start_startpartmarker {
my ($target,$token,$tagstack,$parstack,$parser,$safeeval)=@_;
my $result='';
@@ -1850,7 +1839,7 @@ sub start_startpartmarker {
$result.=&mt('Marker for the start of a part. Place end marker below to wrap in-between tags into a new part.').'';
$result.=&Apache::edit::end_table();
- }
+ }
return $result;
}
@@ -1880,6 +1869,10 @@ sub end_endpartmarker {
return @result;
}
+
+
+
+
sub start_part {
my ($target,$token,$tagstack,$parstack,$parser,$safeeval,$style)=@_;
if (!$Apache::lonxml::metamode) {
@@ -1970,7 +1963,7 @@ sub start_part {
}
} elsif ($target eq 'web') {
if ($status eq 'CAN_ANSWER') {
- my $problemstatus = &get_problem_status($Apache::inputtags::part);
+ my $problemstatus = &get_problem_status($Apache::inputtags::part);
my $probrandomize = &Apache::lonnet::EXT("resource.$Apache::inputtags::partlist[0].type");
my $probrandtries = &Apache::lonnet::EXT("resource.$Apache::inputtags::partlist[0].randomizeontries");
my $num = scalar(@Apache::inputtags::partlist)-1;
@@ -1988,7 +1981,7 @@ sub start_part {
$result .= &randomizetry_part_header($problemstatus,$reqtries,$num);
}
}
- $result.='';
+ $result.='';
}
}
}
@@ -2202,7 +2195,7 @@ sub end_startouttext {
.''
.'
'
.&Apache::lonhtmlcommon::dragmath_button($areaid,1)
- .' | '
+ .''
.''
.&Apache::edit::insertlist($target,$token)
.' | '