On the client in the browser, I have this code:
this.socket.on('initial', function(data) { console.log(data); });
On the server, I have:
socket.sockets.on('connection', function(client){ console.log('client connected'); });
My question is: how can I determine the url where the request came from? For example, if the first closure was done on "/ posts / view / 1", I want to be able to detect it inside the second closure.
source share