mirror of
https://github.com/moodle/moodle.git
synced 2025-03-13 20:26:32 +01:00
updated essay code to work with quotes being used in user answer and teacher response
This commit is contained in:
parent
ec6dc3f6d7
commit
611e79fd75
@ -1753,10 +1753,10 @@
|
||||
|
||||
$essayinfo->graded = 1;
|
||||
$essayinfo->score = $form->score;
|
||||
$essayinfo->response = $form->response;
|
||||
$essayinfo->response = stripslashes_safe($form->response);
|
||||
$essayinfo->sent = 0;
|
||||
|
||||
$essay->useranswer = serialize($essayinfo);
|
||||
$essay->useranswer = addslashes(serialize($essayinfo));
|
||||
|
||||
if (!update_record("lesson_attempts", $essay)) {
|
||||
error("Could not update essay score");
|
||||
@ -1840,7 +1840,7 @@
|
||||
|
||||
if(email_to_user($users[$essay->userid], $USER, $subject, $plaintxt, $message)) {
|
||||
$essayinfo->sent = 1;
|
||||
$essay->useranswer = serialize($essayinfo);
|
||||
$essay->useranswer = addslashes(serialize($essayinfo));
|
||||
update_record("lesson_attempts", $essay);
|
||||
} else {
|
||||
echo "Email Failed!<br>";
|
||||
|
Loading…
x
Reference in New Issue
Block a user