Hi ryan, Thanks for the reply, but the chat application if working properly which means the socket.io is defined properly in the server side code. In my above post it's listening to port 3050, but when I go to port 300, the chat is now working and I can login to the site. If I make them listed to the same port, I'm getting error.
Thanks again On Saturday, January 18, 2014 8:46:52 AM UTC+8, ryandesign wrote: > > > On Jan 17, 2014, at 04:59, almarjin <[email protected] <javascript:>> > wrote: > > > I'm trying to create a chat application with login. I have manage to > make the chat and login work in a separate application but when integrating > them, they dont work. > > > > I'm getting this error: > > > > Failed to load resource: the server responded with a status of 404 (Not > Found) http://dev.nodejs.putoshop.com:3000/socket.io/socket.io.js > > Uncaught ReferenceError: io is not defined dev.nodejs.putoshop.com/:14 > > > > I'm using EJS for my template engine. If I go to the port(3050) where > the chat application is listening, the chat application is working and when > I go to main port which is 3000, I can login but the chat application is > not working and showing the error above. > > It sounds like in your server-side code you have forgotten to require(' > socket.io') and make it listen to your app. That’s what makes the path / > socket.io/socket.io.js return the right script instead of the 404 error > you’re getting. > > http://socket.io/#how-to-use > > > -- -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en --- You received this message because you are subscribed to the Google Groups "nodejs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
