How to solve Socket IO warning ‘Unknown Transport : “flashsocket”‘

If you have tried to connect to a NodeJS socket IO server from Adobe Flash or Flex using Flash Socket,  you might have experienced connection error and seen a warning in the NodeJS server console saying ‘Unknown Transport : “flashsocket”’. This can be solved by enabling the ‘flashsocket’ transport method which  is disabled by default in the newer versions of SocketIO.

var io = require('socket.io').listen(server, {transports:['flashsocket', 'websocket', 'htmlfile', 'xhr-polling', 'jsonp-polling']});

That’s it. Happy coding.

Leave a Reply