I am trying to read a response from a socket I have written on a Java application. However the PHP is just hanging. Here is the code I am using to read from the socket:
while($resp = socket_read($socket, 1000)) {
$str .= $resp;
if (strpos($str, "\n") !== false) {
break;
}
}
When I run the socket call from terminal there is deffinately a response.
Thanks,