We had the same issue and we could solve it by increasing the "maximum number of bytes" parameter in the socket_read() function. You can try
The reason is that websocket header in chrome sometimes is greater that 1024 bytes. So, when your server reads 1024 bytes, it does not get Sec-Websocket-Key parameter and it can not generate valid Sec-Websocket-Accept value.
You can also use fsockopen() and fread() instead of socket_read() function.