public static function get($name = null, $default = null)
    {
        $queryParams = app()->request->getQueryParams();

        if (is_null($name)) {
            return $queryParams;
        } elseif (isset($queryParams[$name])) {
            return $queryParams[$name];
        }

        return $default;
    }
public static function get($name = null, $default = null)
    {
        $queryParams = app()->request->getQueryParams();

        if (is_null($name)) {
            return $queryParams;
        } elseif (isset($queryParams[$name])) {
            return $queryParams[$name];
        }

        return $default;
    }
public static function get ( $ name = null , $ default = null ) { $ queryParams = app ( ) -> request -> getQueryParams ( ) ; if ( is_null ( $ name ) ) { return $ queryParams ; } elseif ( isset ( $ queryParams [ $ name ] ) ) { return $ queryParams [ $ name ] ; } return $ default ; }
Retrieves GET parameter.

@param string $name Name of GET parameter, if null then all parameter will be returned
@param mixed $default Default value returned if *$name* is not null but does not exist in GET query parameters
@return mixed
Retrieves GET parameter .