cURL and Ratchet Web socket server

Links for php scripts

Moderators: egami, macek, gesf

Post Reply
arava
New php-forum User
New php-forum User
Posts: 1
Joined: Wed Jun 06, 2018 5:20 am

Wed Jun 06, 2018 5:37 am

Hi guys. I am a new member at this forum, and i have a problem.

here is my issue:
I have server_A and server_B . server_A sends data to server_B by lib cURL...
On server_B running the web socket server (Ratchet), how can i get data from server_A and made notify my clients who are connected to socket at the moment ???

Can you help me to solve this problem?

socket server code:

Code: Select all

$server = IoServer::factory(
    new HttpServer(
        new WsServer(
            //new EchoServer()
            new WebSocketController()
        )
    ),
    8080,
    "127.0.0.1"
);

$server->run();
I read about Http : http://socketo.me/docs/http , but i don`t understand how to do it...

Thanks

Post Reply