r/PHPhelp • • Sep 27 '25
Making Real Time Chat System
I have made a working chat system, but i want to add private chat + real time so you dont have to refresh.
2
Upvotes
r/PHPhelp • • Sep 27 '25
I have made a working chat system, but i want to add private chat + real time so you dont have to refresh.
11
u/abrahamguo Sep 27 '25
How about using websockets, in that case?
1
u/Nice-Signature8858 Sep 27 '25
Don't just use PHP, but use AJAX at a minimum. You can create a function with a timer of X seconds to execute an AJAX request to a PHP file that retrieves your data. This is the most basic method, not the most efficient.
3
u/nickk21321 Sep 28 '25
You can do with AJAX as mentioned by someone. Can do in vanilla PHP. The feedback is realtime if backend data processing response is less
1
u/Timely-Tale4769 Sep 28 '25
ReactPHP with ratchet is a good choice for websocket. But, you need a dedicated port for websocket.
1
u/TheaterTon Sep 28 '25
Laravel Framework with Reverb server. I’m using this in a similar project.
0
u/[deleted] Sep 28 '25
Custom SSE Server with ReactPHP
-5
u/thegamer720x Sep 28 '25
Chatgpt and Claude AI are your best friends. Use them .
-12
u/[deleted] Sep 27 '25
For info, i'm 100% new and i have just used deepseek, i don't know my code.