所以我在error.log中得到了这个错误,并且无法弄清楚如何修复它。我尝试在Stack Overflow上搜索类似的类似问题,但没有取得任何成功。一些帮助将不胜感激!
标记的行是显示错误的位置:
if(isset($_GET['id']) && !empty($_GET['id'])){
//If statement content here...
} elseif(isset($_GET['category']) && !empty($_GET['category'])) {
$_GET['category'] = $database->escape_string(filter_var($_GET['category'], FILTER_SANITIZE_STRING));
// This line:
$category_title = $database->query("SELECT `name` FROM `categories` WHERE `slug` = '{$_GET['category']}'")->fetch_object()->name;
$pageTitle = 'something';
$description = 'something';
$keywords = $category_title;
$indexTitle = $category_title;
}