-
Notifications
You must be signed in to change notification settings - Fork 2
Request: __construct Example
Terry L edited this page Jun 20, 2020
·
2 revisions
Shieldon\Psr7\Request
Extends Message.
-
param
string
method= "GET"
Request HTTP method. -
param
string|UriInterface
uri= ""
Request URI object URI or URL. -
param
string|StreamInterface
body= ""
Request body - see setBody() -
param
array
headers= []
Request headers. -
param
string
version= "1.1"
Request protocol version.
Example:
$request = new \Shieldon\Psr7\Request('GET', 'https://www.example.com');
composer require shieldon/psr-http
Shieldon PSR HTTP implementation written by Terry L. from Taiwan.