No title Revision 613065363635 (Thu Jun 28 2012 at 17:47) - Diff Link to this snippet: https://friendpaste.com/3C3JbrHvNfHDdRUZ38aMZG Embed: manni perldoc borland colorful default murphy trac fruity autumn bw emacs pastie friendly Show line numbers Wrap lines 12345678910111213141516171819202122232425262728# Imagine this one script""" <iq type='set' to= 'roomname@conference.chat.oonair.net' id='id1'> <oo xmlns='http://oonair.com/muc#share'> <item name='Falda tubo' thumbnail='http://webpage.info/falda_tn.jpg' id='itemid1' action='add' url='http://webpage.info/falda.htmlÃÂâÃÂÃÂÃÂÃÂ> <metadata path=' ' /> </item> </oo></iq>"""class Item(ElementBase): name = 'item' namespace = 'http://oonair.com/muc#share' plugin_attrib = 'item' interfaces = set(('name', 'thumbnail', 'id', 'action', 'url', 'metadata')) sub_interfaces = set(('metadata'))class OO(ElementBase): name = 'oo' namespace = 'http://oonair.com/muc#share' plugin_attrib = 'oo_muc_share' interfaces = set(('item')) sub_interfaces = interfaces subitem = (Item,) # And this one will be going in the xmpp client scriptregister_stanza_plugin(Iq, OO, Item, iterable = True)