Ask a PHP websocket implementation question

Source: Internet
Author: User
Websocket is used in the project. It is estimated that the concurrency will not be high. It can support more than a hundred people. It should be easy to implement with node, but I would like to try it with php, now the problem is that after opening a page, the second one cannot be connected, and the server clearly shows a new connection, but the customer... websocket is used in the project. It is estimated that the concurrency will not be very high. It can support hundreds of people,
It should be easy to implement with node, but I want to try it with php,
The problem now is that after opening a page, the second one cannot be connected. The server clearly shows a new connection, but the client has no response and is not very familiar with the socket part, which of the following can help you.

Here is a related article
Here are the server code and test address respectively.

============
I seem to know why. The disConnect method does not reset $ handshake. After the change, I open several more browsers and the connection status is usually 3. Why?

Reply content:

Websocket is used in the project. It is estimated that the concurrency will not be very high. It can support hundreds of people,
It should be easy to implement with node, but I want to try it with php,
The problem now is that after opening a page, the second one cannot be connected. The server clearly shows a new connection, but the client has no response and is not very familiar with the socket part, which of the following can help you.

Here is a related article
Here are the server code and test address respectively.

============
I seem to know why. The disConnect method does not reset $ handshake. After the change, I open several more browsers and the connection status is usually 3. Why?

The modified server code has been fixed.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.