The HttpRequest
PHP Manual

HttpRequest::setMethod

(PECL pecl_http >= 0.10.0)

HttpRequest::setMethodSet method

说明

public bool HttpRequest::setMethod ( int $request_method )

Set the request method.

参数

request_method

the request method to use

返回值

成功时返回 TRUE, 或者在失败时返回 FALSE.


The HttpRequest
PHP Manual