From: Norman R. <no...@ra...> - 2009-08-22 11:46:14
|
Try: html = Node('html') html.setNamespace('http://jabber.org/protocol/xhtml-im') xhtml = html.addChild('body',namespace='http://www.w3.org/1999/xhtml') xhtml.addData('Hello ') xhtml.addChild('strong', payload='strong') xhtml.addData(' World!') client.send(xmpp.protocol.Message(to, msg, payload=[xhtml])) You can also use XML2Node to convert an xml string into a Node that you can pass as payload to Message or add as a child to the html element. Cheers Norman On Fri, Aug 21, 2009 at 7:06 AM, Charles McLaughlin <mcl...@gm...>wrote: > Hi, > > First of all, thanks for the great work. I'd like to know how to do > minor formatting. I tried html tags such as <a> and <strong> but > they're not rendered in Pidgin. I suspect the python xmpp module is > escaping the tags? Is there a way to work around this? > > This is how I'm sending the messages: > > client.send(xmpp.protocol.Message(to, msg)) > > Thanks, > Charles > > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day > trial. Simplify your report design, integration and deployment - and focus > on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > Xmpppy-devel mailing list > Xmp...@li... > https://lists.sourceforge.net/lists/listinfo/xmpppy-devel > -- - Norman Rasmussen - Email: no...@ra... - Home page: http://norman.rasmussen.co.za/ |