nowelium / socket.io-titanium

socket.io for titanium mobile
http://youtu.be/10ogNjWCpyc
Other
136 stars 34 forks source link

android is not working. #19

Open mhpc0909 opened 11 years ago

mhpc0909 commented 11 years ago

I've tried all the instructions and ios is fine but android devices do not make any communication with server. ----------------------------------------------------------------- SERVER var io = require('socket.io').listen(8080);

var chat = io.of('/chat');

chat.on('connection', function(socket){ socket.emit('available_channel', 'asdfasdf'); });

----------------------------------------------------------------- CLIENT in Titanium 3.1

var io = require('socket.io-titanium'); var socket = io.connect('192.168.0.9:8080'); var chat = socket.of('/chat');

chat.on('available_channel', function(channels){ alert(channels); });

alert('hi there!!!');


also added 32768

android doesn't come in chat.on().