public function getRequestedRoute($basepath)
    {
        if ($basepath == '/') {
            $url = strtolower($_SERVER['REQUEST_URI']);
        } else {
            $url = explode($basepath, strtolower($_SERVER['REQUEST_URI']))[1];
        }

        return $this->_router->getRoute($url);
    }
public function getRequestedRoute($basepath)
    {
        if ($basepath == '/') {
            $url = strtolower($_SERVER['REQUEST_URI']);
        } else {
            $url = explode($basepath, strtolower($_SERVER['REQUEST_URI']))[1];
        }

        return $this->_router->getRoute($url);
    }
public function getRequestedRoute ( $ basepath ) { if ( $ basepath == '/' ) { $ url = strtolower ( $ _SERVER [ 'REQUEST_URI' ] ) ; } else { $ url = explode ( $ basepath , strtolower ( $ _SERVER [ 'REQUEST_URI' ] ) ) [ 1 ] ; } return $ this -> _router -> getRoute ( $ url ) ; }
Gets the requested route for the controller.

@param string $basepath - Application's base path

@return array
Gets the requested route for the controller .