How to perform X-FACEBOOK-PLATFORM and Google Talk X-OAUTH2 XMPP authentication with PHP Jaxl library

Posted 21 CommentsPosted in Open Source, PHP, XMPP
Ever since Jaxl library first introduced support for X-FACEBOOK-PLATFORM XMPP authentication mechanism, it has changed significantly. Also, Google Talk now supports OAuth 2.0 Authorization, an XMPP extension to allow users to log in using OAuth 2.0 credentials. Both these mechanisms are a big win for XMPP developers, since real-time conversation experience can now be provided to their application users without asking them for their passwords. In this blog post, I will demonstrate how to perform X-FACEBOOK-PLATFORM and X-OAUTH2 XMPP authentication mechanism using Jaxl v3.x PHP Library. X-FACEBOOK-PLATFORM XMPP Authentication Here is a quick guide on how to perform X-FACEBOOK-PLATFORM XMPP...

Working with Jaxl – A Networking Library in PHP – Part 1 – An Introduction, Philosophy and History

Posted 3 CommentsPosted in Open Source, PHP, XMPP
Development of Jaxl library started way back in December'07 while I was working on a self-initiated project called Gtalkbots. The project is now dead, if you are interested in knowing more about it go through Gtalkbots BlogSpot. Jaxl v1.x was first released in Jan'09 and about a year later in Aug'10 Jaxl v2.x was released. First two versions were released as JAbber XMPP Library for writing clients and external server components. While working on my startup Jaxl - A Platform As A Service (PAAS) for developing real-time applications, I started experiencing v2.x limitations when my external server side components were...

Announcing Jaxl v3.x – asynchronous, non-blocking I/O, event based PHP client/server library

Posted 22 CommentsPosted in Open Source, PHP, XMPP
Jaxl v3.x is a successor of v2.x (and is NOT backward compatible), carrying a lot of code from v2.x while throwing away the ugly parts. A lot of components have been re-written keeping in mind the feedback from the developer community over the last 4 years. Also Jaxl shares a few philosophies from my experience with erlang and python languages. Jaxl is an asynchronous, non-blocking I/O, event based PHP library for writing custom TCP/IP client and server implementations. From it's previous versions, library inherits a full blown stable support for XMPP protocol stack. In v3.0, support for HTTP protocol stack...

JAXL library – List of available hooks for various XMPP events

Posted 12 CommentsPosted in XMPP
Jaxl 2.x provides an event mechanism using which developers can register callbacks for various xmpp events inside their application code. This blog post will demonstrate how to register callbacks for required xmpp events and go through a list of all available hooks. Finally, we will discuss parameters that are passed to called back methods by Jaxl core. Registering callback on XMPP events Applications can register callback for various XMPP events. Jaxl core will then callback application methods (with 2 parameters) every time associated XMPP event occurs. Shown below are some sample examples for registering callbacks. When application callback'd method is...

PHP Code, Setup and Demo of Jaxl boshchat application

Posted 86 CommentsPosted in PHP, XMPP
Jaxl 2.0 bosh support allow web developers to write real time web applications within minutes, without having any pre-requisite knowledge about the XMPP protocol itself. In this blog post, I will walk you through setup and demo of an XMPP based web chat application using Jaxl library. Get the code Follow the following steps to download and install this sample web application on your systems: Clone the development branch of Jaxl library [email protected]:~/git# git clone [email protected]:abhinavsingh/JAXL.git [email protected]:~/git# cd JAXL/ [email protected]:~/git/JAXL# If you are not familiar with git, simply visit [email protected], click Download Source and extract under ~/git/JAXL directory on your...

Releasing Jaxl 2.0 – Object oriented XMPP framework in PHP

Posted 7 CommentsPosted in Open Source, PHP, XMPP
After months of restructuring the Jaxl library, I am pleased to announce Jaxl 2.0, an object oriented XMPP framework in PHP for developing real time applications for browsers, desktops and hand held devices. What's new in Jaxl 2.0? A lot of structural changes has been done from the previous version to make it more scalable, robust, flexible and easy to use Library now provides an event mechanism, allowing developers to register callbacks for various xmpp events in their application code Use integrated BOSH support to write real time web applications in minutes More than 10 new implemented XMPP extensions (XEP's)...

Introducing WP-Chat :: XMPP Chat plugin for WordPress

Posted 49 CommentsPosted in WordPress, XMPP
WP-Chat plugin embeds Jaxl IM (Instant Messenger for the web) for wordpress blogs. It runs across all major browsers and built upon XMPP protocol. It is a hosted solution from Jaxl.im empowering real time communication between you and your site visitors. It expects no software or hardware pre-requisites from your site servers or users. Above all it's free! Overview: Supports for all major browser including Firefox, Chrome, Safari and IE Embeddable on all blogs, forums, personal, social and enterprise sites Built using XMPP protocol (backbone for facebook and google chats) Hosted dashboard for site admins and IM users Pluggable and...

Setting up ejabberd 2.1.x development environment on Ubuntu

Posted 13 CommentsPosted in XMPP
apt-get provide a convenient way of installing ejabberd on Ubuntu distributions. However, if you are an erlang developer and looking to write custom ejabberd modules, you might want to install ejabberd from the source code. Checkout ejabberd source To start with lets grab the ejabberd 2.1.x branch source code: sudo apt-get install git-core git clone git://git.process-one.net/ejabberd/mainline.git ejabberd cd ejabberd git checkout -b 2.1.x origin/2.1.x cd src Installing pre-requisites Lets setup necessary pre-requisites before compiling ejabberd source code: sudo apt-get install build-essential sudo apt-get install automake autoconf sudo apt-get install erlang erlang-manpages sudo apt-get install libexpat1-dev zlib1g-dev libssl-dev Compiling ejabberd source...

JAXL BOSH Demo: IM chat client for all WordPress blogs

Posted 37 CommentsPosted in WordPress, XMPP
Have you ever wished of a wordpress plugin capable of providing a facebook style chat bar on your blog post. In this blog post, I will lay down the details of how Jaxl's bosh support comes in handy for building such browser based real time application. Specifically, I will explain how I achieved building a plugin for my wordpress blog. If everything goes perfect over next few weeks, this plugin might be submitted in wordpress plugin's directory. Jaxl BOSH Support Framework Jaxl BOSH support comprise of three main parts: jaxl.jquery.js: JQuery extension written for Jaxl bosh support jaxl4bosh.class.php: Connection manager...

Get real time system & server load notification on any IM using PHP and XMPP

Posted 21 CommentsPosted in XMPP
There are various system and server related information which server administrators always need to have as soon as possible, infact I must say in real time. There are several open and closed source softwares in the market which can generate almost real time notifications for you. Most famous one being Nagios. In this blog post I will discuss, how to generate real time system notifications using PHP and XMPP. Specifically, I will present sample script using Jaxl (Jabber XMPP Client Library) for generating real time system load notifications, which can be received using any Instant Messengers. /proc/loadavg We will be...