Fix timeout

Timeout option doesn't work and "No Content-Length field found in the HTTP header." exception is thrown.

stream_set_timeout() must be used : 
> http://www.php.net/manual/en/function.fsockopen.php (in "timeout" parameter)
If you need to set a timeout for reading/writing data over the socket, use stream_set_timeout(), as the timeout parameter to fsockopen() only applies while connecting the socket.