[LON-CAPA-cvs] cvs: loncom /homework inputtags.pm
raeburn
raeburn at source.lon-capa.org
Sun Mar 11 16:17:10 EDT 2012
raeburn Sun Mar 11 20:17:10 2012 EDT
Modified files:
/loncom/homework inputtags.pm
Log:
- Bug 6558.
No wrapping of student submission in HTML::Entities::encode() when showing
student's response to student, post-answerdate.
Index: loncom/homework/inputtags.pm
diff -u loncom/homework/inputtags.pm:1.301 loncom/homework/inputtags.pm:1.302
--- loncom/homework/inputtags.pm:1.301 Sun Jan 29 03:02:52 2012
+++ loncom/homework/inputtags.pm Sun Mar 11 20:17:10 2012
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# input definitons
#
-# $Id: inputtags.pm,v 1.301 2012/01/29 03:02:52 raeburn Exp $
+# $Id: inputtags.pm,v 1.302 2012/03/11 20:17:10 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -185,7 +185,7 @@
}
}
unless ($newvariation) {
- $oldresponse = &HTML::Entities::encode($Apache::lonhomework::history{"resource.$partid.$resid.submission"},'<>&"');
+ $oldresponse = $Apache::lonhomework::history{"resource.$partid.$resid.submission"};
}
if ($Apache::inputtags::status[-1] eq 'CAN_ANSWER') {
my $cols = &Apache::lonxml::get_param('cols',$parstack,$safeeval);
@@ -200,7 +200,7 @@
my $textareaclass = 'class="LC_richDetectHtml"';
$result.= '<textarea wrap="hard" name="HWVAL_'.$resid.'" id="HWVAL_'.$resid.'" '.
'rows="'.$rows.'" cols="'.$cols.'" '.$textareaclass.'>'.
- $oldresponse;
+ &HTML::Entities::encode($oldresponse,'<>&"');
if ($oldresponse ne '') {
#get rid of any startup text if the user has already responded
More information about the LON-CAPA-cvs
mailing list