|
@@ 6475-6490 (lines=16) @@
|
| 6472 |
|
$tbl_lp_item = Database :: get_course_table(TABLE_LP_ITEM); |
| 6473 |
|
$tbl_quiz = Database :: get_course_table(TABLE_QUIZ_TEST); |
| 6474 |
|
|
| 6475 |
|
if ($id != 0 && is_array($extra_info)) { |
| 6476 |
|
$item_title = $extra_info['title']; |
| 6477 |
|
$item_description = $extra_info['description']; |
| 6478 |
|
} elseif (is_numeric($extra_info)) { |
| 6479 |
|
$sql = "SELECT title, description |
| 6480 |
|
FROM " . $tbl_quiz . " |
| 6481 |
|
WHERE c_id = ".$course_id." AND id = " . $extra_info; |
| 6482 |
|
|
| 6483 |
|
$result = Database::query($sql); |
| 6484 |
|
$row = Database::fetch_array($result); |
| 6485 |
|
$item_title = $row['title']; |
| 6486 |
|
$item_description = $row['description']; |
| 6487 |
|
} else { |
| 6488 |
|
$item_title = ''; |
| 6489 |
|
$item_description = ''; |
| 6490 |
|
} |
| 6491 |
|
$item_title = Security::remove_XSS($item_title); |
| 6492 |
|
$item_description = Security::remove_XSS($item_description); |
| 6493 |
|
|
|
@@ 6896-6911 (lines=16) @@
|
| 6893 |
|
$tbl_lp_item = Database :: get_course_table(TABLE_LP_ITEM); |
| 6894 |
|
$tbl_forum = Database :: get_course_table(TABLE_FORUM); |
| 6895 |
|
|
| 6896 |
|
if ($id != 0 && is_array($extra_info)) { |
| 6897 |
|
$item_title = stripslashes($extra_info['title']); |
| 6898 |
|
} elseif (is_numeric($extra_info)) { |
| 6899 |
|
$sql = "SELECT forum_title as title, forum_comment as comment |
| 6900 |
|
FROM " . $tbl_forum . " |
| 6901 |
|
WHERE c_id = ".$course_id." AND forum_id = " . $extra_info; |
| 6902 |
|
|
| 6903 |
|
$result = Database::query($sql); |
| 6904 |
|
$row = Database :: fetch_array($result); |
| 6905 |
|
|
| 6906 |
|
$item_title = $row['title']; |
| 6907 |
|
$item_description = $row['comment']; |
| 6908 |
|
} else { |
| 6909 |
|
$item_title = ''; |
| 6910 |
|
$item_description = ''; |
| 6911 |
|
} |
| 6912 |
|
|
| 6913 |
|
if ($id != 0 && is_array($extra_info)) { |
| 6914 |
|
$parent = $extra_info['parent_item_id']; |