php - Getting online friends using Jabber (XMPP) -


I am facing a problem communicating with the server:

  [ Request] & lt; Stream: stream = "chat.facebook.com" for XMLName: stream = "http://etherx.jabber.org/streams" xmlns = "jabber: client" version = "1.0" & gt; [Feedback]  [Feedback] & lt; Challenge xmlns = "vase: ietf: param: xml: ns: xmpp-sasl" & gt; [Deleted] & lt; / Challenge & gt; [Request] & lt; Reaction xmlns = "karash: ietf: params: xml: ns: xmpp-sasl" & gt; [Deleted] & lt; / Reaction & gt; [Feedback] & lt; Success xmlns = "vase: ietf: param: xml: ns: xmpp-sasl" /> [Feedback]  & Lt; Session xmlns = "kalash: ietf: params: xml: ns: xmpp-session" /> & Lt; / Stream: Feature & gt; [Request] & lt; Iq type = "set" id = "1" & gt; Bind xmlns = "vase: ietf: params: xml: ns: xmpp-bind" /> & Lt; / Iq & gt; [Feedback] & lt; Iq id = "1" type = "result" & gt; Bind xmlns = "vase: ietf: param: xml: ns: xmpp-bind" & gt; & Lt; Jid & gt; - [deleted] @chat.facebook.com / [delete] & lt; / JID & gt; & Lt; / Bind & gt; & Lt; / IQ & gt; [Request] & lt; Iq type = "set" id = "2" = "chat.facebook.com" & gt; & Lt; Session xmlns = "blur: ietf: parameters: xml: ns: xmpp-session" /> & Lt; / IQ & gt; [Feedback] & lt; Iq type = "results" to "chat.facebook.com" id = "2" & gt; & Lt; Session xmlns = "karash: ietf: params: xml: ns: xmpp-session" /> & Lt; / IQ & gt; [Request] & lt; Iq type = "get" id = "3" = "- [deleted] @ chat.facebook.com / [deleted]" & gt; Query xmlns = "jabber: iq: roster" /> & Lt; / IQ & gt;   

The problem is the final request:

  [request]  & Lt; / Iq & gt;   

Which, according to the document [?], Should only be returned to online users, however, it gives all the user friends instead. How can I get / filter online users only?

The document is RFC 3921 or better yet, which will soon get an RFC number See the section for information on how to get your roster recovered, which is a list of all your contacts, it does not matter that their presence status is to get the presence of the people you subscribe to, Send your presence to begin They are.

You send:

  & lt; Appearance & gt;   

And each of your online contacts will receive the location of attendance from:

  & lt; Appearance from''friend1@example.com/ DeviceID / & gt; & Lt; Appearance from''friend2@example.com/deviceID/>   

etc. You do not know when "all" of the presence has been received, because when this happens your contact can change their appearance. Instead, think about moving forward in the information flow of the presence, where you will be updated as soon as possible, then any changes will be reported.

Comments