diff --git a/main/exercice/exercise.class.php b/main/exercice/exercise.class.php index 542c5deb70..84600065fb 100644 --- a/main/exercice/exercise.class.php +++ b/main/exercice/exercise.class.php @@ -2276,7 +2276,7 @@ class Exercise { $str = str_replace('\r\n', '', $str); $choice = $arr[1]; - $tmp = api_strrpos($choice[$j],' / '); + $tmp = api_strrpos($choice[$j],' / '); $choice[$j] = api_substr($choice[$j],0,$tmp); $choice[$j] = trim($choice[$j]); @@ -3439,6 +3439,7 @@ class Exercise { public function is_visible($lp_id = 0, $lp_item_id = 0 , $lp_item_view_id = 0, $filter_by_admin = true) { //1. By default the exercise is visible $is_visible = true; + $message = null; //1.1 Admins and teachers can access to the exercise if ($filter_by_admin) { diff --git a/main/exercice/exercise.lib.php b/main/exercice/exercise.lib.php index 275e5fa655..9be6be97c5 100644 --- a/main/exercice/exercise.lib.php +++ b/main/exercice/exercise.lib.php @@ -203,6 +203,8 @@ function showQuestion($questionId, $only_questions = false, $origin = false, $cu $numAnswer = $objAnswerTmp->selectAutoId($answerId); $comment = $objAnswerTmp->selectComment($answerId); + $attributes = array(); + // Unique answer if ($answerType == UNIQUE_ANSWER || $answerType == UNIQUE_ANSWER_NO_OPTION) { $input_id = 'choice-'.$questionId.'-'.$answerId; diff --git a/main/exercice/question.class.php b/main/exercice/question.class.php index a53c524346..ddbd3e7ca1 100644 --- a/main/exercice/question.class.php +++ b/main/exercice/question.class.php @@ -1460,7 +1460,7 @@ abstract class Question // display question category, if any $header = Testcategory::returnCategoryAndTitle($this->id); - + $show_media = null; if ($show_media) { $header .= $this->show_media_content(); } diff --git a/main/inc/global.inc.php b/main/inc/global.inc.php index 88a94b1a9c..5141b6826d 100644 --- a/main/inc/global.inc.php +++ b/main/inc/global.inc.php @@ -307,8 +307,8 @@ if (!$x = strpos($_SERVER['PHP_SELF'], 'whoisonline.php')) { // ===== end "who is logged in?" module section ===== if (api_get_setting('server_type') == 'test') { - //error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED); - error_reporting(-1); + error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED); + //error_reporting(-1); } else { /* Server type is not test