diff --git a/public/index.php b/public/index.php index ee4c162..8be460c 100644 --- a/public/index.php +++ b/public/index.php @@ -5,6 +5,9 @@ require '../main.php'; // very basic routing $host = $_SERVER["REQUEST_SCHEME"] . '://' . $_SERVER["SERVER_NAME"]; $url = $_SERVER['REQUEST_URI']; +if (($pos = strpos($url, '?')) !== false) { + $url = substr($url, 0, $pos); +} switch($url) { case '/game': $controller = new MapGuesser\Controller\GameController();