To send a simple string to a socket (not websocket), the following snippets works on node.js. Is it possible to do something similar on the client side?
var net = require('net');
var client = new net.Socket();
client.connect(port, ip, function() {
client.write(message);
});
Basically I want to send a string to a simple socket (not a websocket) on the network from the browser. how would I do it?