A
A
Aricus2020-11-22 14:26:45
PHP
Aricus, 2020-11-22 14:26:45

How to enable websockets in XAMPP?

I already asked this question over a year ago, but then no one answered. It is still relevant, so I will repeat.
I'm new to web sockets and I don't understand anything. I need in a project to make web sockets operating inside the local network on a XAMPP server (Windows 10). Check script

if(extension_loaded('sockets')) echo "WebSockets OK";
else echo "WebSockets UNAVAILABLE";

gives "WebSockets UNAVAILABLE"
Here's what I tried:
  • unlocked the line in php.ini:
    extension=sockets
  • added to php.ini line:
    extentions=php_sockets.dll
  • wrote in the project folder console:
    php php-socket.php
    Could not open input file: php-socket.php

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question