Changeset 958 for trunk/Modules/News/NewsPage.php
- Timestamp:
- Sep 23, 2023, 12:04:04 AM (15 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Modules/News/NewsPage.php
r957 r958 24 24 { 25 25 $Category = $this->GetCategory(); 26 if (array_key_exists('id', $_GET) and is_ integer($_GET['id'])) $Id = $_GET['id'] * 1;26 if (array_key_exists('id', $_GET) and is_numeric($_GET['id'])) $Id = $_GET['id'] * 1; 27 27 else return $Output .= 'Položka nenalezena.'; 28 28 $DbResult = $this->Database->query('SELECT `News`.*, `User`.`Name` FROM `News` '. … … 296 296 { 297 297 $Category = array('Id' => 1); // Default category 298 if (array_key_exists('category', $_GET) and is_ integer($_GET['category'])) $Category['Id'] = $_GET['category'] * 1;299 if (array_key_exists('category', $_POST) and is_ integer($_POST['category'])) $Category['Id'] = $_POST['category'] * 1;298 if (array_key_exists('category', $_GET) and is_numeric($_GET['category'])) $Category['Id'] = $_GET['category'] * 1; 299 if (array_key_exists('category', $_POST) and is_numeric($_POST['category'])) $Category['Id'] = $_POST['category'] * 1; 300 300 //if (is_null($Category)) throw new Exception('Kategorie neurčena'); 301 301 else … … 412 412 foreach ($Parts as $Part) 413 413 { 414 if (is_ integer($Part)) $Where .= 'OR (`Category`='.($Part * 1).')';414 if (is_numeric($Part)) $Where .= 'OR (`Category`='.($Part * 1).')'; 415 415 } 416 416 $Where = substr($Where, 2);
Note:
See TracChangeset
for help on using the changeset viewer.