How to communicate with openfire via PHP

Hi,

I have had a look around for a good library to communicate with my openfire server via php, however this is proving to be much harder than expected. XMPPHP is returning BOSH errors and JAXL is not faring much better. So I thought some of you guys could help me out. I am planning on releasing a very basic chat platform, in that only a few features are required, such as checking if users are online and and sending / receiving messages. The impression that I have got is that both JAXL and XMPPHP have been written for chat bots, not chat clients. So, I thought I would have a go building a PHP class for the basic communication with Openfire. Just a few Q’s:

  1. Is BOSH a necessary part of the process, and is it desired over polling the Openfire server? Please correct me if I am wrong, however after reading around it seems that BOSH is to Openfire => PHP as COMET is to PHP => Javascript. Can cURL be used to handle this.
  2. Can anyone point me in the direction of some openfire documentation detailing where to send such requests and how to implement them. I have looked around and all I can find is XMPP specification links.
  3. If it isn’t in part 2, what is the resource URL to hit in order to make the request?

Thanks,

Hamish

hi…

i want to connect openfire with xmpphp client but i tried much i didn’t connect it. is openfire server not supported to xmpphp client or there is any way to solve this problem …

help plz

Hi, I also am interested in any PHP information on access properly openfire servers.

Best regards,

Paul

Hi,

I use something called:

/* Jabber Client Library

  • Version 0.9rc2
  • Copyright 2002-2007, Centova Technologies Inc.

and it works just fine. You connect directy to the tcp jabber port 5222. The example is straight forward.

daryl

1 Like

Hi Daryl,

Thank you so much. I did not find a direct link to it. After some search I found this:

http://diso.googlecode.com/svn/wordpress/wp-xmpp/trunk/jabber-php/

I downloaded each file independently and it works for me now too.

Thank you so much for your help.

Best regards,

Paul