Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

BeginnerSoul's avatar

Websocket connection custom error page/message

Hello How I can redirect the user if the websocket server is offline or giving them an error custom message?

For example in debug mode I get this error:

Pusher error: cURL error 7: Failed to connect to 127.0.0.1 port 6001: Connection refused

However I would like to give an error custom message or redirect the user to an error page. How can I do that? Thanks in advance the answers.

0 likes
0 replies

Please or to participate in this conversation.