Clickalicious\PhpMemAdmin\App::getHostFromRequest PHP Method

getHostFromRequest() protected method

Returns host from request if exist, otherwise NULL.
Author: Benjamin Carl ([email protected])
protected getHostFromRequest ( ) : null\string
return null\string
    protected function getHostFromRequest()
    {
        $host = null;
        if (isset($_GET['host']) && $_GET['host'] !== '' && in_array($_GET['host'], $this->getHosts()) === true) {
            // Get host from request
            $host = $_GET['host'];
        }
        return $host;
    }