I'm stuck on a problem with getting data from a XML data stream. This
stream is large and trying to use fsockopen to get the stream down.
I've tetsed the code by telneting into the machine/port but I am
getting some of the data but not all. I don't know the stream size.
Code snippit below:
function txrx($server, $port, $tx){
$rx = "";
if ($server == "") {
$rx = "Error - Missing Server";
}
if ($port == "") {
$rx = "Error - Missing Port";
}
$fp = fsockopen($server, $port);
if($fp) {
fputs($fp, $tx);
$rx .= fread($fp, 2048);
fclose($fp);
}
return $rx;
}
Any suggestions ?
Can you please post to the group and send me an e-mail at
34*****@gmail.com
Thanks
Colin Bell