It is possible to do this?

I need to know when a user enters a chatroom and he leaves.

I think that the best form is with a plugin, and to do this:

  • When userevent enter in chatroom, the plugin call a url like this: “http://…/services.php?jid=eee@sss.com/ee&strRoom=sssss&strComm=START/services.php?jid=eee@sss.com/ee&strRoom=sssss&strComm=START”

And when there are a userevet leaving a room, call this other url: “http://…/services.php?jid=eee@sss.com/ee&strRoom=sssss&strComm=STOP/services.php?jid=eee@sss.com/ee&strRoom=sssss&strComm=STOP”

Is possible ???

Thanks !!!

Message was edited by: weiser01

Hi Jose,

It would take a little bit of work but you could do this. What you would have to do is write a plugin that uses a PacketInterceptor that looks for certain specific MUC packets that are sent when users enter/leave rooms. When you detect someone entering/leaving you could then open a connection to the specified url by doing something like:

URL u = new URL("http://..../services.php?jid=eee@sss.com/ee&strRoom=sssss&strComm=START");
URLConnection uc = u.openConnection();
uc.connect();

Hope that helps,

Ryan