Prev: help using phpadmin
Next: enabling domdocument
From: "Gary ." on 19 Jul 2010 03:45 How can I get calls to scoket_read to timeout if the server stops responding? It's not clear exactly what's happening, but occasionally the server simply stops sending data and my php code (client) then sits there waiting endlessly. I know about set_time_limit but I don't want to abandon the entire script, just the reading of data from the server (I can at least give a meaningful error message then, for example).
From: "Gary ." on 19 Jul 2010 04:10 On Mon, Jul 19, 2010 at 9:45 AM, Gary wrote: > How can I get calls to scoket_read to timeout if the server stops > responding? Sorry. Found it: socket_set_option($sock, SOL_SOCKET, SO_RCVTIMEO, array('sec' => 1, 'usec' => 0));
|
Pages: 1 Prev: help using phpadmin Next: enabling domdocument |