diff --git a/main/coursecopy/classes/CourseBuilder.class.php b/main/coursecopy/classes/CourseBuilder.class.php index d6717c6221..70fde67634 100644 --- a/main/coursecopy/classes/CourseBuilder.class.php +++ b/main/coursecopy/classes/CourseBuilder.class.php @@ -1,4 +1,4 @@ -add_answer($obj2->answer, $obj2->correct, $obj2->comment, $obj2->ponderation, $obj2->position); + $question->add_answer($obj2->answer, $obj2->correct, $obj2->comment, $obj2->ponderation, $obj2->position, $obj2->hotspot_coordinates, $obj2->hotspot_type); } $this->course->add_resource($question); } diff --git a/main/coursecopy/classes/CourseRestorer.class.php b/main/coursecopy/classes/CourseRestorer.class.php index 0199dd2bc3..da55d0864e 100644 --- a/main/coursecopy/classes/CourseRestorer.class.php +++ b/main/coursecopy/classes/CourseRestorer.class.php @@ -1,7 +1,7 @@ answers as $index => $answer) { - $sql = "INSERT INTO ".$table_ans." SET id= '". ($index +1)."',question_id = '".$new_id."', answer = '".Database::escape_string($answer['answer'])."', correct = '".$answer['correct']."', comment = '".Database::escape_string($answer['comment'])."', ponderation='".$answer['ponderation']."', position = '".$answer['position']."'"; + $sql = "INSERT INTO ".$table_ans." SET id= '". ($index +1)."',question_id = '".$new_id."', answer = '".Database::escape_string($answer['answer'])."', correct = '".$answer['correct']."', comment = '".Database::escape_string($answer['comment'])."', ponderation='".$answer['ponderation']."', position = '".$answer['position']."', hotspot_coordinates = '".$answer['hotspot_coordinates']."', hotspot_type = '".$answer['hotspot_type']."'"; api_sql_query($sql, __FILE__, __LINE__); } $this->course->resources[RESOURCE_QUIZQUESTION][$id]->destination_id = $new_id; diff --git a/main/coursecopy/classes/QuizQuestion.class.php b/main/coursecopy/classes/QuizQuestion.class.php index 55ee9d1e8d..54134250d7 100644 --- a/main/coursecopy/classes/QuizQuestion.class.php +++ b/main/coursecopy/classes/QuizQuestion.class.php @@ -1,4 +1,4 @@ -answers[] = $answer; } /**