From 7a61f613ec04f714312d54b538dbf773057759ea Mon Sep 17 00:00:00 2001 From: slawkens Date: Sun, 14 May 2023 08:15:44 +0200 Subject: [PATCH] Revert "Workaround for links from fb, like ?fbclid=x" This reverts commit 073d9da0bc13363222227b8c2c0d07c9210f50b3. --- index.php | 15 +++------------ templates/kathrine/template.php | 2 +- 2 files changed, 4 insertions(+), 13 deletions(-) diff --git a/index.php b/index.php index 1b655195..7cb6ba67 100644 --- a/index.php +++ b/index.php @@ -74,24 +74,15 @@ if((!isset($config['installed']) || !$config['installed']) && file_exists(BASE . throw new RuntimeException('Setup detected that install/ directory exists. Please visit this url to start MyAAC Installation.
Delete install/ directory if you already installed MyAAC.
Remember to REFRESH this page when you\'re done!'); } -$isEmptyGet = false; -if (!empty($_GET)) { - foreach ($_GET as $value) { - if (empty($value)) { - $isEmptyGet = true; - } - } -} - $found = false; -if(empty($uri) || isset($_REQUEST['template']) || (!$isEmptyGet && !isset($_REQUEST['subtopic']) && !isset($_REQUEST['p']))) { - $_REQUEST['p'] = $_REQUEST['subtopic'] = 'news'; +if(empty($uri) || isset($_REQUEST['template'])) { + $_REQUEST['p'] = 'news'; $found = true; } else { $tmp = strtolower($uri); if(!preg_match('/[^A-z0-9_\-]/', $uri) && file_exists(SYSTEM . 'pages/' . $tmp . '.php')) { - $_REQUEST['p'] = $_REQUEST['subtopic'] = $uri; + $_REQUEST['p'] = $uri; $found = true; } else { diff --git a/templates/kathrine/template.php b/templates/kathrine/template.php index 49abc110..063b0648 100644 --- a/templates/kathrine/template.php +++ b/templates/kathrine/template.php @@ -33,7 +33,7 @@ defined('MYAAC') or die('Direct access not allowed!'); } else { $tmp = URI; - if(empty($tmp) || !$isEmptyGet) { + if(empty($tmp)) { $tmp = array('news'); } else {