xmppJidGetBareJid()

This function returns the bare jid part of a jabber ID.

Synopsis

string xmppJidGetBareJid(string jid);

Parameter

Parameter Description
jid Jabber ID such as "winccoa.etm@jabber.at"

Return Value

Returns the bare jid part of a jabber ID.

Errors

Errors can be queried via getLastError().

Description

This function returns the bare jid part of a jabber ID, e.g. xmppJidGetUser("winccoa.etm@jabber.at/server") => " winccoa.etm@jabber.at"

The following example shows how to query the bare jid part of a jabber ID.

Note: You have to replace the code: p = xmppOpen("winccoa.etm@jabber.at","123677", "callback", m); DebugN("xmppOpen:", p); by your own user and password. This code is an example!
#uses "CtrlXmpp"
int p;
main(mapping event)
{
  p = xmppOpen("winccoa.etm@jabber.at","123677");
  DebugN("xmppOpen:", p);
  string s = xmppJidGetBareJid("winccoa.etm@jabber.at");
  DebugN("The pure JID:", s);
}

Assignment

XMPP functions

Availability

CTRL