Merge pull request #32 from mremi/filter-request-headers
Added method to tweak HTTP headers of request
This commit is contained in:
commit
02722eae8f
|
@ -178,6 +178,8 @@ class SoapClient extends \SoapClient
|
|||
$headers = array();
|
||||
}
|
||||
|
||||
$headers = $this->filterRequestHeaders($soapRequest, $headers);
|
||||
|
||||
// execute HTTP request with cURL
|
||||
$responseSuccessfull = $this->curl->exec(
|
||||
$location,
|
||||
|
@ -258,6 +260,19 @@ class SoapClient extends \SoapClient
|
|||
return $soapResponse;
|
||||
}
|
||||
|
||||
/**
|
||||
* Filters HTTP headers which will be sent
|
||||
*
|
||||
* @param SoapRequest $soapRequest SOAP request object
|
||||
* @param array $headers An array of HTTP headers
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
protected function filterRequestHeaders(SoapRequest $soapRequest, array $headers)
|
||||
{
|
||||
return $headers;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get last request HTTP headers.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue