Thursday 12 July 2012

OpenFire Sub Group

XMPP has concept of chat rooms. A chat room is basically a conference room where users can discuss on some points. But Yahoo has provided room facility as social chatting rooms where any member can join the group and chat with other members. In this feature "nested chat rooms" are provided.

XMPP is not basically providing nested or child chat rooms. But twisting the logic little bit can make it possible with normal XMPP also.

Recall the concepts of domain name. Facebook has domain "facebook.com". Then they have started services of application. They bought sub domain. That became "apps.facebook.com".

Similarly in XMPP suppose you are creating chat room with name University. The JID will be something like "university@domain.com". Now you want different universities as sub chat room of this one. Just create sub University as "oxford.university@domain.com". The main logic that you need to take care is at the client side. You need to show this rooms in tree structure so that user will see it as sub chat room instead of independent chat room.

Creating chat rooms from admin panel is very easy. It is just a html form filling task. But for creating a chat room from client is real programming stuff. You can get information about it from this link. Remember in XMPP room has many types. If you want to keep the room alive forever. You will have to create persistent room. Other rooms will be removed as soon as the last occupant will leave the room.

Let me know if you have any queries regarding all this.



0 comments:

Post a Comment