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

LaylowZK's avatar

Laravel WebSocket - Realtime App

Hi, can someone help me? Im developing a quiz game using websocket. It is working fine when is in my localhost computer, but when i put it online, it display the error below:

WebSocket connection to 'ws://quiz.interactive.ga:6001/app/anyKey?protocol=7&client=js&version=5.1.1&flash=false' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED

and

WebSocket connection to 'wss://quiz.interactive.ga/app/anyKey?protocol=7&client=js&version=5.1.1&flash=false' failed: Error during WebSocket handshake: Unexpected response code: 404

and

Access to XMLHttpRequest at 'http://sockjs.pusher.com/pusher/app/anyKey/85/qk45join/xhr_streaming?protocol=7&client=js&version=5.1.1&t=1588772650094&n=1' from origin 'http://quiz.interactive.ga' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.

What do i have to do? I'm using Laravel and Vue.

0 likes
0 replies

Please or to participate in this conversation.