Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
|
Public Member Functions | |
__construct () | |
setConfig ($config=array()) | |
getConfig () | |
setCurlOption ($option, $value) | |
connect ($host, $port=80, $secure=false) | |
write ($method, $uri, $httpVersion=1.1, $headers=array(), $body='') | |
read () | |
close () | |
getHandle () | |
setOutputStream ($stream) | |
readHeader ($curl, $header) | |
Protected Attributes | |
$_config = array() | |
$_connected_to = array(null, null) | |
$_curl = null | |
$_invalidOverwritableCurlOptions | |
$_response = null | |
$out_stream | |
__construct | ( | ) |
Adapter constructor
Config is set using setConfig()
Zend_Http_Client_Adapter_Exception |
Definition at line 100 of file Curl.php.
close | ( | ) |
Close the connection to the server
Implements Zend_Http_Client_Adapter_Interface.
Definition at line 496 of file Curl.php.
connect | ( | $host, | |
$port = 80 , |
|||
$secure = false |
|||
) |
Initialize curl
string | $host | |
int | $port | |
boolean | $secure |
Zend_Http_Client_Adapter_Exception | if unable to connect |
Implements Zend_Http_Client_Adapter_Interface.
Definition at line 202 of file Curl.php.
getConfig | ( | ) |
read | ( | ) |
Return read response from server
Implements Zend_Http_Client_Adapter_Interface.
Definition at line 487 of file Curl.php.
readHeader | ( | $curl, | |
$header | |||
) |
setConfig | ( | $config = array() | ) |
Set the configuration array for the adapter
Zend_Http_Client_Adapter_Exception |
Zend_Config | array | $config |
Implements Zend_Http_Client_Adapter_Interface.
Definition at line 132 of file Curl.php.
setCurlOption | ( | $option, | |
$value | |||
) |
setOutputStream | ( | $stream | ) |
Set output stream for the response
resource | $stream |
Implements Zend_Http_Client_Adapter_Stream.
write | ( | $method, | |
$uri, | |||
$httpVersion = 1.1 , |
|||
$headers = array() , |
|||
$body = '' |
|||
) |
Send request to the remote server
string | $method | |
Zend_Uri_Http | $uri | |
float | $http_ver | |
array | $headers | |
string | $body |
Zend_Http_Client_Adapter_Exception | If connection fails, connected to wrong host, no PUT file defined, unsupported method, or unsupported cURL option |
Make sure POSTFIELDS is set after $curlMethod is set: http://de2.php.net/manual/en/function.curl-setopt.php#81161
Implements Zend_Http_Client_Adapter_Interface.
Definition at line 279 of file Curl.php.