ChatJS is a full-featured, lightweight, Facebook style jQuery plugin for instant messaging. ChatJS also comes with a server side implementation for ASP.NET/SignalR out of the box.
Download Leave demo chat
... or visit the project at GitHub.
How it works:
The client part is divided in two JavaScript files. The file jquery.chatjs.jscontains the main jQuery plugin
$.chat()
andjquery.chatjs.signalradapter.js contains the adapter function needed to tell the plug-in how to interact with the server.
Once the server is set up, the client code is quite simple. These are all the options:
$.chat({ // your user information user: { Id: 3, Name: 'John Silver', ProfilePictureUrl: 'http://www.foo.com/avatar/123' }, // text displayed when the other user is typing typingText: ' is typing...', // the title for the user's list window titleText: 'ChatJS demo chat', // text displayed when there's no other users in the room emptyRoomText: "There's no one around here.", // the adapter you are using adapter: new SignalRAdapter() });
Features:
- Real time message sharing (Oh really?).
- Automatically parses URLs and emoticons .
- Automatically remembers opened windows across diferent requests (through cookies).
- Triggers a sound notification when the user receives a message.
- Indicates when the other user is typing.
- Supports multiple chat rooms. If you have a multi-tenancy app you can create a room for each tenancy, for instance.
- Supports multiple browser windows opened with the same session. They all get properly sinchronized.
- Customizable texts. You can easily translate it to your language.
- Both client and server code ready to be used for ASP.NET with SignalR.
No comments:
Post a Comment