[FLOW3-general] timeout retrieve file via HTTP\Client\Browser

Thomas Mammitzsch thomas at visualworx.de
Mon Mar 25 16:51:13 CET 2013


Hi Bastian,

thanks, works on my dev machine but strange error in production:

PHP Fatal error:  Call to undefined method 
TYPO3\Flow\Http\Client\CurlEngine::setOption() in ...

i don't get it

On 25.03.2013 16:04, Bastian Waidelich wrote:
> Thomas Mammitzsch wrote:
>
> Hi Thomas,
>
>> i get timeout errors when trying to receive a file via
>> HTTP\Client\Browser after 5 seconds. How to avoid that?
>
>
> If you use CURL (the default request engine) you can set the timeout 
> like:
>
> $browser->getRequestEngine()->setOption(CURLOPT_TIMEOUT, 123);
>
>> Maybe you have also a hint how to best save the file to disc.
>
> what about
>
> file_put_contents($filePathAndName, 
> $browser->request($uri)->getContent());
>
> ?
>
>



More information about the FLOW3-general mailing list