@bel, I am trying to have multiple browsers open at one time with the ability to change something in one browser and push a notification to the all open browsers. I believe a websocket is the way to go. I have opened one on /ws and can see a change when it is made. However, I am just re-running a get which is a constant refresh until I close the socket. Instead, I would like to just send the notification. If I have to refresh the page, to see the data update than that is fine but the primary goal is to receive a notification on another browser. I am not sure if there is an example already where I can see how to go about this.
I have tried civetweb/example/_obsolete/websocket/WebSockCallbacks.c there is a websock_send_broadcast. I get a segmentation fault using this API.
I have tried using the mg_set_user_connection_data(conn,data); But when I use the mg_get_user_data(conn) I get a "invalid conversion from ‘void*’ to ‘t_ws_client*".
Any direction would be greatly appreciated.
Best Regards,
JMil