|
|
@ -1658,7 +1658,8 @@ class Exercise { |
|
|
|
* @return string html code |
|
|
|
* @return string html code |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
function manage_answer($exeId, $questionId, $choice, $from = 'exercise_show', $exerciseResultCoordinates = array(), $saved_results = true, $from_database = false, $show_result = true) { |
|
|
|
function manage_answer($exeId, $questionId, $choice, $from = 'exercise_show', $exerciseResultCoordinates = array(), $saved_results = true, $from_database = false, $show_result = true) { |
|
|
|
global $_configuration; |
|
|
|
global $_configuration, $feedback_type; |
|
|
|
|
|
|
|
|
|
|
|
$questionId = intval($questionId); |
|
|
|
$questionId = intval($questionId); |
|
|
|
$exeId = intval($exeId); |
|
|
|
$exeId = intval($exeId); |
|
|
|
$TBL_TRACK_ATTEMPT = Database::get_statistic_table(TABLE_STATISTIC_TRACK_E_ATTEMPT); |
|
|
|
$TBL_TRACK_ATTEMPT = Database::get_statistic_table(TABLE_STATISTIC_TRACK_E_ATTEMPT); |
|
|
@ -1673,6 +1674,7 @@ class Exercise { |
|
|
|
$answerType = $objQuestionTmp->selectType(); |
|
|
|
$answerType = $objQuestionTmp->selectType(); |
|
|
|
$quesId = $objQuestionTmp->selectId(); |
|
|
|
$quesId = $objQuestionTmp->selectId(); |
|
|
|
$extra = $objQuestionTmp->extra; |
|
|
|
$extra = $objQuestionTmp->extra; |
|
|
|
|
|
|
|
|
|
|
|
//Extra information of the question |
|
|
|
//Extra information of the question |
|
|
|
if (!empty($extra)){ |
|
|
|
if (!empty($extra)){ |
|
|
|
$extra = explode(':', $extra); |
|
|
|
$extra = explode(':', $extra); |
|
|
@ -2188,6 +2190,7 @@ class Exercise { |
|
|
|
} // end switch Answertype |
|
|
|
} // end switch Answertype |
|
|
|
|
|
|
|
|
|
|
|
global $origin; |
|
|
|
global $origin; |
|
|
|
|
|
|
|
|
|
|
|
if ($show_result) { |
|
|
|
if ($show_result) { |
|
|
|
|
|
|
|
|
|
|
|
if ($from == 'exercise_result') { |
|
|
|
if ($from == 'exercise_result') { |
|
|
|