tpiros / advanced-chat Goto Github PK
View Code? Open in Web Editor NEWLicense: The Unlicense
License: The Unlicense
when starting node server.js i get an error:
app.configure<function()
typeError: undefined is not a function...
could you please help me fix this?
thanks
Hi,
I am not able to run the code taken from Github (https://github.com/tamaspiros/advanced-chat)it is not responding and also no errror logs are generating.Shall i have to run the client js also for this purpose.
Please help.
Regards,
Nishant
hi.. i got a problem with whispering to other user..
problem is here
okay, when client A send "hello" whisper to client B,
client A got this message "NaN:NaN:NaN undefined whispers: undefined"
while client B got this message "20:43:03 pja whispers: hello"
how to fix this thing?
Can you please tell me what wrong with me . I am getting this error when i run the server.js
Hello, I do not know why the variable timeout
is not being cleaned. From the moment that the user stoped typing, the timeout
is not being cleaned and is appearing on the screen that the User is still typing ... http://stackoverflow.com/questions/39008144/nodejs-socket-user-is-typing-issues
when i try to setup localy i get this error
[email protected] install C:\Users\Mohamed\Desktop\ya rab\node_modules\socket.io\node_
modules\socket.io-client\node_modules\ws
(node-gyp rebuild 2> builderror.log) || (exit 0)
C:\Users\Mohamed\Desktop\ya rab\node_modules\socket.io\node_modules\socket.io-cl
ient\node_modules\ws>node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp
-bin....\node_modules\node-gyp\bin\node-gyp.js" rebuild
/
[email protected] postinstall C:\Users\Mohamed\Desktop\ya rab
./node_modules/bower/bin/bower install
'.' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! [email protected] postinstall: ./node_modules/bower/bin/bower install
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script.
npm ERR! This is most likely a problem with the chat package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! ./node_modules/bower/bin/bower install
npm ERR! You can get their info via:
npm ERR! npm owner ls chat
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nod
ejs\node_modules\npm\bin\npm-cli.js" "install"
npm ERR! cwd C:\Users\Mohamed\Desktop\ya rab
npm ERR! node -v v0.10.31
npm ERR! npm -v 1.4.23
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! C:\Users\Mohamed\Desktop\ya rab\npm-debug.log
npm ERR! not ok code 0
any help please ?
Hi ;) nice and well-explained source code.
Can a user belongs to more than one chat-room?? E.g., participate in two or more chat rooms.
How can I achieve this?
Thanks ;)
can the Whisper messages be opened in new window and store the messages in mysql !!
like friend list system
The server crashed when I tried the following:
one person creates a room, another person joins it, then leaves it and tries to come back. The system info says: You are already in a room (Dev's room), please leave it first to join another room.
and the log from the server:
info - socket.io started
connect.multipart() will be removed in connect 3.0
visit https://github.com/senchalabs/connect/wiki/Connect-3.0 for alternatives
connect.limit() will be removed in connect 3.0
Express server up and running.
match: false
undefined
match: false
matched person
T1's room
match: false
/Users/and_re/Sites/advanced-chat/server.js:229
date", "You are already in a room ("+rooms[people[socket.id].inroom].name+"),
^
TypeError: Cannot read property 'name' of undefined
at io.sockets.on.socket.on.room (/Users/and_re/Sites/advanced-chat/server.js:229:94)
at check (/Users/and_re/Sites/advanced-chat/server.js:37:20)
at process.startup.processNextTick.process._tickCallback (node.js:244:9)
29 Oct 10:33:23 - [nodemon] app crashed - waiting for file changes before starting...
i did all instructions but it doesn't work.
info - socket.io started
connect.multipart() will be removed in connect 3.0
visit https://github.com/senchalabs/connect/wiki/Connect-3.0 for alternatives
connect.limit() will be removed in connect 3.0
warn - error raised: Error: listen EADDRINUSE
and crush CSS.
this is the debug log:
0 info it worked if it ends with ok
1 verbose cli [ 'C:\Program Files (x86)\nodejs\node.exe',
1 verbose cli 'C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js',
1 verbose cli 'start' ]
2 info using [email protected]
3 info using [email protected]
4 verbose node symlink C:\Program Files (x86)\nodejs\node.exe
5 verbose run-script [ 'prestart', 'start', 'poststart' ]
6 info prestart [email protected]
7 info start [email protected]
8 verbose unsafe-perm in lifecycle true
9 info [email protected] Failed to exec start script
10 error [email protected] start: node server.js
10 error Exit status 1
11 error Failed at the [email protected] start script.
11 error This is most likely a problem with the chat package,
11 error not with npm itself.
11 error Tell the author that this fails on your system:
11 error node server.js
11 error You can get their info via:
11 error npm owner ls chat
11 error There is likely additional logging output above.
12 error System Windows_NT 6.1.7601
13 error command "C:\Program Files (x86)\nodejs\node.exe" "C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js" "start"
14 error cwd C:\Users\Sharon\Desktop\advanced-chat-master
15 error node -v v0.10.35
16 error npm -v 1.4.28
17 error code ELIFECYCLE
18 verbose exit [ 1, true ]
Just FYI, the selector breaks when a person has a name like "Some Bro", anything with a space. I didn't clone your repo or anything so I'm just posting the issue + fix here. In clien.js
socket.on("isTyping", function(data) {
if (data.isTyping) {
if ($("#"+data.person.split(' ').join('-')+"").length === 0) {
$("#updates").append("<li id='"+ data.person.split(' ').join('-') +"'> " + data.person + " is typing.");
......MY CUSTOM CALLBACK, OMITTED
}
} else {
$("#"+data.person.split(' ').join('-')+"").remove();
}
});
As you can see it's a simple matter of splitting where any spaces are and joining by a non space char. Cool app, much thanks for sharing it. :)
I installed the current version on Ubuntu 12.04. The directory for jquery.js was incorrect. It needs to have ./dist added so that the entire directory is:
components/jquery/dist/jquery.js
Took a liberty of copying your code and make it run under socket.io ver 1 and express 4 located here: https://github.com/forddyce/programme-chameleon/tree/master/public/app
Was going to add download feature (I will add a table and when a user clicks on download button the
will export as xlsx and download, table created by room master and downloadable by participants). Also going to add feature on showing what room I'm currently at, and a "logout" button without the need of refreshing the page. Any ideas on the feature I mentioned?Advanced-chat is not working well with my angularjs project..
I want to integrate this with my project.. may be i have some problem with jquery?
When whispering to self two error messages are displayed ('can't find ' and 'can't whisper to self') - former is not correct as user == self therefore user exists.
Hi ,
Thanks for building a simple and useful chat application. How can we persist the message into the DB (in mongo or redis)
Advance-chat Not Working properly with my angularjs project ..
info - socket.io started
connect.multipart() will be removed in connect 3.0
visit https://github.com/senchalabs/connect/wiki/Connect-3.0 for alternatives
connect.limit() will be removed in connect 3.0
warn - error raised: Error: listen EADDRINUSE
advanced-chat
looks very useful for an internal project I'm working on, but without a license, I feel very uncomfortable relying on it. Anything "copy left", GPL, or so on pretty much precludes being able to use this. Here's a useful StackOverflow discussion on this topic.
Personally, I like the MIT license or Perl Artistic 2 licenses :)
css problem and nothing is displayed when we type any message or create room
i have this chat running from a nginx proxy, and when i load it from the url everything works, but when i embed the script into my site and connect it doesnt work.
Any idea ?
Dude!
Can u deploy demo online because I cant build your project!
Can u provide the components folder?? thanks in advance
From my experience on underscore.js, I don't really understand the following codes.
Do you think that it's the right way on using the call of contains(".contains") ?
For example, in the logic " if(.contains((room.people)), s.id) ", (_.contains((room.people)), s.id) is always true, because s.id is always greater than 0.
If so, kindly review the following codes, and let me know.
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L80
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L75
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L100
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L105
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L121
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L126
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L141
https://github.com/tamaspiros/advanced-chat/blob/master/server.js#L154
the client io.connect port doesn't work like in this example anymore on production site
Hello Tamas,
I was newbie for using socket.io and your advanced-chat project was really great for me to learn about chat engine with socket.io.
But When I try to use it, the cpu always heap until 104%, so the next request can't handle by server. So it always show warning "WebSocket is closed before the connection is established". What should I do Tamas? Is there any way to fix this issue?
My server spec is 4 CPUs and 8GB RAM.
Cheers.
Are you going to upgrade to express 4? Thanks
Hey there,
I'm attempting to run this on OpenShift, and I get to the HTML but I get the following 404's (see below).
I assume it's a problem with Express but I cannot for the life of me figure out what.
Failed to load resource: the server responded with a status of 404 (Not Found)
http://nodesocketapp-dodan.rhcloud.com/components/font-awesome/css/font-awesome.css Failed to load resource: the server responded with a status of 404 (Not Found)
http://nodesocketapp-dodan.rhcloud.com/components/bootstrap/dist/js/bootstrap.js Failed to load resource: the server responded with a status of 404 (Not Found)
http://nodesocketapp-dodan.rhcloud.com/components/jquery/dist/jquery.js Failed to load resource: the server responded with a status of 404 (Not Found)
client.js:82 Uncaught ReferenceError: $ is not defined
http://nodesocketapp-dodan.rhcloud.com/components/bootstrap/dist/css/bootstrap.css Failed to load resource: the server responded with a status of 404 (Not Found)
http://nodesocketapp-dodan.rhcloud.com/components/font-awesome/css/font-awesome.css Failed to load resource: the server responded with a status of 404 (Not Found)
hi
in whisper message
io.sockets.socket(whisperId).emit("whisper", people[socket.id], whisperMsg)
this is not working anymore in socket.io 1.x
is there any solution for this?
thanks.
I got the following error message:
Error: EACCES, permission denied '/var/run/advanced-chat.pid
What could be wrong? Thanks.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.