diff --git a/main/inc/lib/exercise.lib.php b/main/inc/lib/exercise.lib.php index a739dde55f..dd1977da6c 100644 --- a/main/inc/lib/exercise.lib.php +++ b/main/inc/lib/exercise.lib.php @@ -622,12 +622,12 @@ class ExerciseLib * the text to find mustn't contains HTML tags * the text to find mustn't contains char " */ - global $exerciseId; + global $exe_id; $trackAttempts = Database::get_main_table( TABLE_STATISTIC_TRACK_E_ATTEMPT ); $sql = 'SELECT answer FROM ' . $trackAttempts . ' - WHERE exe_id=' . $exerciseId . ' AND question_id=' . $questionId; + WHERE exe_id=' . $exe_id . ' AND question_id=' . $questionId; $rsLastAttempt = Database::query($sql); $rowLastAttempt = Database::fetch_array($rsLastAttempt); $answer = $rowLastAttempt['answer'];