Quote:
Originally Posted by n___
I get the same error as above when attempting to connect with NodeJS and socket.io
Not familiar with sp, any pointers on where I might be going wrong?
The client.html.txt code works to send messages to the server, but not the following node code
Code:
var io = require('socket.io-client'),
socket = io.connect('myhost.com', {
port: 12345
});
socket.on('connect', function() {
socket.send("Hello Websockets from Node!");
});
|
If you're trying to communicate with the server using anything besides a web browser (in this case, it looks like you're trying to facilitate communication between a game server and a Node.js program?), you should really use plain sockets.
__________________