Subject: How to query for room information
n 'XEP-0045: Multi-User Chat', it describe that through the following method we can get the chat room information:
Example 6. User Queries for Information about a Specific Chat Room
<iq from='hag66@shakespeare.lit/pda'
id='disco2'
to='macbeth.shakespeare.lit'
type='get'>
<query xmlns='http://jabber.org/protocol/disco#items'/>
</iq>
The room MUST return its identity and SHOULD return the features it supports:
Example 7. Room Returns Disco Info Results
<iq from='macbeth.shakespeare.lit'
id='disco2'
to='hag66@shakespeare.lit/pda'
type='result'>
<query xmlns='http://jabber.org/protocol/disco#items'>
<item jid='heath@macbeth.shakespeare.lit'
name='A Lonely Heath'/>
<item jid='darkcave@macbeth.shakespeare.lit'
name='A Dark Cave'/>
<item jid='forres@macbeth.shakespeare.lit'
name='The Palace'/>
<item jid='inverness@macbeth.shakespeare.lit'
name='Macbeth's Castle'/>
</query>
</iq>
In my implementation, I send the following iq to query for room information:
<iq from="fl@sysd-marry/agsXMPP"
id="agsXMPP_8"
type="get" to="testroom@conference.sysd-marry">
<query xmlns="http://jabber.org/protocol/disco#info" />
</iq>
but the server return the following iq:
<iq xmlns="jabber:client"
from="testroom@conference.sysd-marry"
to="fl@sysd-marry/agsXMPP"
type="result"
id="agsXMPP_8">
<query xmlns="http://jabber.org/protocol/disco#info"><feature var="http://jabber.org/protocol/disco#info" />
</query>
</iq>
why it can't return the room information?
Example 6. User Queries for Information about a Specific Chat Room
<iq from='hag66@shakespeare.lit/pda'
id='disco2'
to='macbeth.shakespeare.lit'
type='get'>
<query xmlns='http://jabber.org/protocol/disco#items'/>
</iq>
The room MUST return its identity and SHOULD return the features it supports:
Example 7. Room Returns Disco Info Results
<iq from='macbeth.shakespeare.lit'
id='disco2'
to='hag66@shakespeare.lit/pda'
type='result'>
<query xmlns='http://jabber.org/protocol/disco#items'>
<item jid='heath@macbeth.shakespeare.lit'
name='A Lonely Heath'/>
<item jid='darkcave@macbeth.shakespeare.lit'
name='A Dark Cave'/>
<item jid='forres@macbeth.shakespeare.lit'
name='The Palace'/>
<item jid='inverness@macbeth.shakespeare.lit'
name='Macbeth's Castle'/>
</query>
</iq>
In my implementation, I send the following iq to query for room information:
<iq from="fl@sysd-marry/agsXMPP"
id="agsXMPP_8"
type="get" to="testroom@conference.sysd-marry">
<query xmlns="http://jabber.org/protocol/disco#info" />
</iq>
but the server return the following iq:
<iq xmlns="jabber:client"
from="testroom@conference.sysd-marry"
to="fl@sysd-marry/agsXMPP"
type="result"
id="agsXMPP_8">
<query xmlns="http://jabber.org/protocol/disco#info"><feature var="http://jabber.org/protocol/disco#info" />
</query>
</iq>
why it can't return the room information?