My favorites | Sign in
Project Home Downloads Issues
Project Information
Members
Featured
Downloads
Links

Jaxl 2.1.2 is out!, Jaxl 2.1.2 makes the library simple and easier to use in your existing projects. Removed build.sh dependency and added a lot of performance enhancements to the library core. You can find a raw list of what is new reading the Jaxl 2.1.2 Changelog page

Follow @imjaxlim on twitter for development and release updates. For questions, feature requests, insights, bugs, patches, etc use google group mailing list. Fork for commit patches and contribute to Jaxl using Github tools.


About

Jaxl 2.x is an object oriented XMPP framework in PHP for developing real time applications for browsers, desktops and hand held devices. Jaxl 2.x is a robust, flexible and easy to use version of Jaxl 1.x series which was hosted at google code.


What's new with Jaxl 2.x?

  • More robust, flexible, scalable and easy to use
  • Event mechanism for registering callbacks for various xmpp events
  • Integrated support for Real Time Web (XMPP over Bosh) application development
  • 32 implemented XMPP extensions (XEP's)
  • Setup dynamic number of parallel XMPP sessions on the fly
  • Options for monitoring, usage stat collection, rate limiting, etc.

Download

Warning: the development source code is only intended for people that want to develop Jaxl or absolutely need the latest features still not available on the stable releases.


Writing XMPP apps using JAXL library

  • Download and extract inside /path/to/jaxl
  • Jaxl library provide an event based mechanism exposing hooks like jaxl_post_auth
  • Register callback(s) inside your app code for required events (see example below)
  • Write your app logic inside callback'd methods

Here is how a simple send chat message app looks like using Jaxl library:

// Include and initialize Jaxl core
require_once '/path/to/jaxl/core/jaxl.class.php';
$jaxl = new JAXL(array(
    'user'=>'username',
    'pass'=>'password',
    'host'=>'talk.google.com',
    'domain'=>'gmail.com',
    'authType'=>'PLAIN',
    'logLevel'=>4
));

// Send message after successful authentication
function postAuth($payload, $jaxl) {
    global $argv;
    $jaxl->sendMessage($argv[1], $argv[2]);
    $jaxl->shutdown();
}

// Register callback on required hook (callback'd method will always receive 2 params)
$jaxl->addPlugin('jaxl_post_auth', 'postAuth');

// Start Jaxl core
$jaxl->startCore('stream');

Run from command line:

php sendMessage.php "anotherUser@gmail.com" "This is a test message"`

Documentation

Powered by Google Project Hosting