This site preserved for posterity. Woven in its current incarnation will take shape at www.woven.org
 

Integrated chat

  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 702.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 702.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 720.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/marksmarty/markdown.php on line 1143.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/urlfilter/urlfilter.module on line 68.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/urlfilter/urlfilter.module on line 70.
  • warning: Creating default object from empty value in /srv/www/woven/wovenlabs.com/htdocs/sites/wovenlabs.com/modules/spam/spam.module on line 488.

One critical component of an effective Workspace is integrated chat. The user should not need to fuss with downloading an IM client, and real-time communications should be seamless. Some aggregated notes follow.

Module: Chatroom
http://www.drupal.org/project/chatroom

Issue: Work with the OG (groups) paradigm
http://drupal.org/node/71324

Ideally, it works like Gmail Chat, only with the ability to have group chat — so I can see who in the group is online, and I click to chat with one or many of them, and the chat box persists as I navigate around the rest of the site doing my thing.

The above would be ideal, but having a dedicated always-active chat room for the group might be a strong place to start. For example, perhaps a chat room is automatically created when a new group is created and given the same name as the group. (With chatroom.module, there is the concept of “chats” below “chatrooms”, so maybe a “Default” chat is created?) Maybe it can be “popped out” to a new window so I can still move around my workspace while chatting. As a themer, I should be able to place a link to that chat where I want it, so people can easily click to launch the group’s chat.

Here are some possible uber-tasks for the ideal scenario:

  1. Allow for easy spawning of one-to-one chats. Integrate with “who’s online” functionality (see Drupal core’s block of the same name) — may require shoring up this functionality to real presence awareness, as reliable as Gmail’s is. Should allow for ability to click username, which brings up chat window (anchored to bottom right as in Gmail). Chat box should pop up on receiving end and discussion ensues.
  2. Of course, the above requires a method for persisting the layer across pages within Drupal, which may require further AJAX-ifying other aspects of Drupal to allow for this. Requires research.
  3. Integrate the above with OG, i.e. make an OG-specific block with group members, clicking them brings up anchored chat dialogue (as in 1). This way, if I’m in a group, and other group members are online, I can easily chat w/ them.
  4. Let the user control whether or not others can initiate chats with them. Have a setting like “Receive chats”, on by default.
  5. Group chat. Let me initiate a chat, and invite others to it from the dialogue. The new receiving end would see the chat dialogue pop up with all participants shown.
  6. Log conversations. Create a new node with the chat log nicely formatted (see Gmail’s “Chats” folder). Should only be accessible to chat’s participants — that gets tricky, and depends on thinking of Drupal and nodes in a different way, i.e. some nodes are my very own, like the e-mail concept.

I’ll leave it there for now, and will flesh it out as we go.

Submitted by Anonymous on Thu, 06/29/2006 - 11:33pm.

hi dave,

first, my general approach to this will be to try to implement features that meet the OG integration needs in a way that makes these features useable by any module. this will probably take a bit longer, and mean that things aren’t always a perfect fit for OG, but i think its the best way to go.

assuming we can settle on some more or less defineable features for the chatroom module, i’ll turn them into issues and work through them from there.

automatically creating a chat

i’m open to suggestion here, but my first thought is that it would be better to create a chatroom, not a chat, for each group. chatrooms are drupal nodes, and allow for easy listing of chat’s that belong to a chatroom, and an edit page where an admin can archive chats (which will produce a page that is probably some of the way towards what you want in point 6), edit the description, etc.

exporting a list of online users with clickable links
the first and easiest place to start is who is participating in a chat that the user viewing the block has access to. anyone participating in a chat is sending regular requests to the server for upates, so we can just return a list of users who have requested an update in the last X seconds.

the harder part will be making it easy for other modules to create lists that correspond to their needs, like your example of who is online in on OG group. the tricky part here is how to determine who is online. to make this real-time, all pages will need to ping the server with an “i am online” message. so perhaps the chatroom module should expose an i am online service, that will allow modules to put a small block of js in their pages which will send ping? and perhaps a hook so that modules can get at this information and customise it for display?

another tricky bit is getting a realtime notification that someone wants to start a chat with you. this also requires pinging the server at regular intervals, and some javascript that fires off some DOM trickery to allow the user to respond to the invitation. this is probably also something that the chatroom module could expose for other modules to use.

popout chats
i’m not sure about the anchored-to-the-page popout chat yet - i think that will be the most complex of all the suggestions. perhaps a first step is to work up a proof of concept “stipped down” view of a chat, where it load in a smaller, fixed size window with only the scrolling msg board and online list in it.

themeing
i’m not really using the theme functions at all, which is primarily because i haven’t RTFM on them yet, so any and all suggestions here are welcome.

logs
you’re point 6. makes me think that its worth exposing blocks with links to chat logs. suggestions here are more than welcome.

cheers
justin