Mark, RFC 3921, section 7 says "Each <item/> element MAY contain a 'name' attribute, which sets the "nickname" to be associated with the JID, as determined by the user (not the contact). The value of the 'name' attribute is opaque."
I would be tempted to interpret this as "the nickname is set by the 'name' attribute when present". In this case, from a protocol compliance stand point, your method 2 would be the right stanza. In practice, the result will unfortunately be implementation dependent... Jean-Louis -----Original Message----- Message: 1 Date: Wed, 4 Oct 2006 20:20:02 -0700 From: "Mark Doliner" <[EMAIL PROTECTED]> Subject: [jdev] Correct way to remove a nickname form a roster item To: <[email protected]> Message-ID: <[EMAIL PROTECTED]> Content-Type: text/plain; charset="us-ascii" Hi, I'm wondering what is the correct way to remove a nickname from a roster item? Method 1: <iq type='set' id='lalala123'><query xmlns='jabber:iq:roster'><item jid='[EMAIL PROTECTED]'><group>Buddies</group></item></query></iq> Method 2: <iq type='set' id='lalala124'><query xmlns='jabber:iq:roster'><item jid='[EMAIL PROTECTED]' name=''><group>Buddies</group></item></query></iq> Or perhaps something else? Thanks! -Mark
