Avoid string id_session - ref BT#7578

1.9.x
Francis Gonzales 11 years ago
parent c61fc5ef1e
commit 9c21f2b376
  1. 2
      main/inc/local.inc.php

@ -822,7 +822,7 @@ if (isset($cidReset) && $cidReset) {
// these lines are usefull for tracking. Indeed we can have lost the id_session and not the cid.
// Moreover, if we want to track a course with another session it can be usefull
if (!empty($_GET['id_session'])) {
if (!empty($_GET['id_session']) && is_numeric($_GET['id_session'])) {
$tbl_session = Database::get_main_table(TABLE_MAIN_SESSION);
$sql = 'SELECT name FROM '.$tbl_session . ' WHERE id="'.intval($_SESSION['id_session']). '"';
$rs = Database::query($sql);

Loading…
Cancel
Save