Ubiety WordPress Plug-In.
Some people might ask why I would write yet another chat plug-in for WordPress. That is a good question, I suppose. Mostly, I wanted to use web sockets instead of the polling method of my previous plugin. Pusher provides an excellent service to facilitate this process. The Ubiety method is much more efficient than that of AjaxChat. AjaxChat is a noisy passenger in the back seat of a car: “Are we there yet? Are we there yet? Hey, are we there yet?.” Ubiety asks politely once and waits. Ubiety is more efficient by not wasting resources asking for new content. On page load, we initiate a web socket to Pusher’s service, subscribe to a ‘channel’, and bind some JavaScript listeners to certain events on that channel. After that, Ubiety will sit still and wait until it is notified of new events. Pusher is a pretty neat service. If you haven’t checked it out, you should peruse http://pusher.com sometime. I guess I could have modified my previous plugin to either use Pusher or the traditional method based upon some configuration settings, but in the end I decided to put it in a separate package. For one, I didn’t want to further clutter the AjaxChat code. Also, by starting from scratch (some what) I’ll be able to revisit some things with a few more years development under my belt and hopefully come up with some better solutions. The other main difference besides the use of the Pusher service as opposed to polling would be this chat plug-in is only for users who are logged in to an account on the blog. This was a common request for AjaxChat and another reason I separated the two. If you want any viewer to be able to chat, use AjaxChat. If you only want registered users, use Ubiety.
Development Version:
$ svn co http://plugins.svn.wordpress.org/ubiety/trunk ubiety

No comments yet.