Open robertfausk opened 2 years ago
My current workaround is:
use Eko\FeedBundle\Feed\Reader;
use Goutte\Client;
$reader = new Reader();
$client = new Client();
$client->request('GET', $url);
$filename = \sprintf('%s%s%s', $this->cacheDir, \DIRECTORY_SEPARATOR, 'stellenticket.xml');
\file_put_contents($filename, $client->getInternalResponse()->getContent());
$items = $reader->load($filename);
I can provide a PR for the docs if wanted.
Hi @robertfausk,
I think your workaround is the only solution available at this time.
To read feed, we are using https://github.com/laminas/laminas-feed/blob/2.16.x/src/Reader/Reader.php which does not seems to allow a proxy.
Thank you
Looks like the reader allows you to set a http client
Laminas\Feed\Reader::setHttpClient.
We just miss a method to pass a client from Eko\FeedBundle\Feed\Reader
to the laminas reader.
My server has to use a proxy when reading feed. Is it possible to configure the
reader
to use a proxy?Or do I have to/can I use a workaround? E.g. load the content of the feed via another library, put it into a file and use the
$reader->($localFilePath)
?