diff options
Diffstat (limited to 'vendor/fguillot/picofeed/lib/PicoFeed/Client/Client.php')
-rw-r--r-- | vendor/fguillot/picofeed/lib/PicoFeed/Client/Client.php | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/vendor/fguillot/picofeed/lib/PicoFeed/Client/Client.php b/vendor/fguillot/picofeed/lib/PicoFeed/Client/Client.php index 84a5cf296..ae93f3e83 100644 --- a/vendor/fguillot/picofeed/lib/PicoFeed/Client/Client.php +++ b/vendor/fguillot/picofeed/lib/PicoFeed/Client/Client.php @@ -38,6 +38,14 @@ abstract class Client private $encoding = ''; /** + * HTTP request headers + * + * @access protected + * @var array + */ + protected $request_headers = array(); + + /** * HTTP Etag header * * @access protected @@ -194,6 +202,16 @@ abstract class Client } /** + * Add HTTP Header to the request + * + * @access public + * @param array $headers + */ + public function setHeaders($headers) { + $this->request_headers = $headers; + } + + /** * Perform the HTTP request * * @access public @@ -645,8 +663,8 @@ abstract class Client public function setConfig($config) { if ($config !== null) { - $this->setTimeout($config->getGrabberTimeout()); - $this->setUserAgent($config->getGrabberUserAgent()); + $this->setTimeout($config->getClientTimeout()); + $this->setUserAgent($config->getClientUserAgent()); $this->setMaxRedirections($config->getMaxRedirections()); $this->setMaxBodySize($config->getMaxBodySize()); $this->setProxyHostname($config->getProxyHostname()); |