WordPress\AiClientDependencies\Psr\Http\Message

ServerRequestFactoryInterface::createServerRequest │ public │ WP 1.0

Create a new server request.

Note that server-params are taken precisely as given - no parsing/processing of the given values is performed, and, in particular, no attempt is made to determine the HTTP method or URI, which must be provided explicitly.

Метод класса: ServerRequestFactoryInterface{}

Хуков нет.

Возвращает

ServerRequestInterface.

Использование

$ServerRequestFactoryInterface = new ServerRequestFactoryInterface();
$ServerRequestFactoryInterface->createServerRequest( $method, $uri, $serverParams ): ServerRequestInterface;
$method(строка) (обязательный)
The HTTP method associated with the request.
$uri(UriInterface|строка) (обязательный)
The URI associated with the request. If
php the value is a string, the factory MUST create a UriInterface instance based on it. .
$serverParams(массив)
Array of SAPI parameters with which to seed
php the generated request instance. .
По умолчанию: []

Код ServerRequestFactoryInterface::createServerRequest() WP 7.1.2

public function createServerRequest(string $method, $uri, array $serverParams = []): ServerRequestInterface;