I want a simple socket connection, where the server should tell the client the total amount of connections (whenever a connection happens), and the client should update the DOM. I feel like socket.io or any other library is too full featured for such a simple reason. Any idea how to do this without libraries? Answer Node.js documentation shows a very
Tag: sockets
Which is the prefered way to add function to sockets in socket.io?
Is there a “prototype” of all sockets connected to socket.io? I want to define some functions that will be available for each connected socket. Currently i have: But i’m defining a ‘new’ hello function for each socket. Is there a socket prototype? so i can have something like: Answer There is, though it doesn’t appear to be available through the
Socket.io not sending cookies in the handshake causing the request to stall
Let me explain my setup. I have multiple domain names that are all CNAME records for a main domain name, such as example.com. example.com -> serverIP company1.example.com -> example.com company2.example.com -> example.com I’m basically developing white labeled versions of our software, where the software simply detects the referrer and knows which logos and stylesheet assets to load. So that is
Java Server Socket transfer String to web socket
My goal is to set up a connection between a Java Server Socket and a browser (using web sockets). So far, the connection works, but my data streams do not. I would like to send a String from the server socket to the web socket. The problems are the input and output streams. The web socket sends “zustimmung” to the