Differences between revisions 4 and 5
Revision 4 as of 2009-11-28 15:06:03
Size: 896
Editor: Elias
Comment: 删除对PageComment2组件的引用
Revision 5 as of 2009-12-25 07:10:32
Size: 897
Editor: localhost
Comment: converted to 1.6 markup
Deletions are marked like this. Additions are marked like this.
Line 4: Line 4:
[[TableOfContents]] <<TableOfContents>>
Line 6: Line 6:
[[Include(ZPyUGnav)]] <<Include(ZPyUGnav)>>
Line 10: Line 10:
SEE: [:CnGtalkBot:GTalk机器人中文版] SEE: [[CnGtalkBot|GTalk机器人中文版]]
Line 39: Line 39:
创建 by -- ZoomQuiet [[[DateTime(2009-01-18T08:11:12Z)]]] 创建 by -- ZoomQuiet [<<DateTime(2009-01-18T08:11:12Z)>>]

xmmpppy 小实例

SEE: GTalk机器人中文版

23号

<[email protected]>

reply-to        [email protected]
to      [email protected]
date    Sun, Jan 18, 2009 at 16:06
subject [CPyUG:77341] Re: python做Gtalk通信,关于中文支持方面的问题

   1 #!/usr/bin/env python
   2 # -*- coding: UTF-8 -*-
   3 
   4 import xmpp
   5 jid = xmpp.protocol.JID('[email protected]')
   6 c = xmpp.Client(jid.getDomain(), debug=[])
   7 c.connect()
   8 c.auth(jid.getNode(), 'xxx')
   9 c.send(xmpp.protocol.Message('[email protected]', '中文测试!'))

中文试过,是可以的。


反馈

创建 by -- ZoomQuiet [2009-01-18 08:11:12]

MiscItems/2009-01-18 (last edited 2009-12-25 07:10:32 by localhost)