Minor - php warnings

skala
Julio Montoya 13 years ago
parent 61ee894824
commit d1addaf9fb
  1. 3
      main/exercice/exercise.class.php
  2. 2
      main/exercice/exercise.lib.php
  3. 2
      main/exercice/question.class.php
  4. 4
      main/inc/global.inc.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) {

@ -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;

@ -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();
}

@ -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

Loading…
Cancel
Save