Fixing php notices

skala
Julio Montoya 14 years ago
parent 0da8f89918
commit 133c5e23c8
  1. 12
      main/group/group.php
  2. 2
      main/group/group_space.php
  3. 5
      main/inc/introductionSection.inc.php

@ -73,12 +73,12 @@ Display::display_introduction_section(TOOL_GROUP);
/*
* Self-registration and unregistration
*/
$my_group_id = Security::remove_XSS($_GET['group_id']);
$my_msg = Security::remove_XSS($_GET['msg']);
$my_group = $_POST['group'];
$my_get_id1 = Security::remove_XSS($_GET['id1']);
$my_get_id2 = Security::remove_XSS($_GET['id2']);
$my_get_id = Security::remove_XSS($_GET['id']);
$my_group_id = isset($_GET['group_id']) ? intval($_GET['group_id']) : null;
$my_msg = isset($_GET['msg']) ? Security::remove_XSS($_GET['msg']) : null;
$my_group = isset($_GET['group']) ? Security::remove_XSS($_POST['group']) : null;
$my_get_id1 = isset($_GET['id1']) ? Security::remove_XSS($_GET['id1']) : null;
$my_get_id2 = isset($_GET['id2']) ? Security::remove_XSS($_GET['id2']) : null;
$my_get_id = isset($_GET['id']) ? Security::remove_XSS($_GET['id']) : null;
if (isset($_GET['action'])) {
switch ($_GET['action']) {

@ -59,7 +59,7 @@ Display::display_header($nameTools.' '.stripslashes($current_group['name']), 'Gr
/* Introduction section (editable by course admin) */
Display::display_introduction_section(group_space_.$_SESSION['_gid']);
Display::display_introduction_section(TOOL_GROUP);
/* Actions and Action links */

@ -105,7 +105,7 @@ if ($intro_editAllowed) {
/* Delete Command */
if ($intro_cmdDel) {
Database::query("DELETE FROM $TBL_INTRODUCTION WHERE id='".$moduleId."' AND session_id='".intval($session_id)."'");
Database::query("DELETE FROM $TBL_INTRODUCTION WHERE c_id = $course_id AND id='".$moduleId."' AND session_id='".intval($session_id)."'");
Display::display_confirmation_message(get_lang('IntroductionTextDeleted'));
}
}
@ -115,7 +115,8 @@ if ($intro_editAllowed) {
/* Retrieves the module introduction text, if exist */
$sql = "SELECT intro_text FROM $TBL_INTRODUCTION WHERE id='".Database::escape_string($moduleId)."' AND session_id='".intval($session_id)."'";
$sql = "SELECT intro_text FROM $TBL_INTRODUCTION
WHERE c_id = $course_id AND id='".Database::escape_string($moduleId)."' AND session_id='".intval($session_id)."'";
$intro_dbQuery = Database::query($sql);
if (Database::num_rows($intro_dbQuery) > 0) {
$intro_dbResult = Database::fetch_array($intro_dbQuery);

Loading…
Cancel
Save