comparison stanzas.js @ 13:161d4ea1c3f8

Migration of the client-side to XMPP.js instead of Strophe.js. Drop BOSH support and add WebSockets support. The server-side is untested, may be broken.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Thu, 03 Nov 2011 14:23:10 -0700
parents
children
comparison
equal deleted inserted replaced
12:d67380657687 13:161d4ea1c3f8
1 var stanzas = {
2 discoInfo: function(aTo, aNode) {
3 if(aTo)
4 var iq = "<iq type='get' to='"+aTo+"'>";
5 else
6 var iq = "<iq type='get'>";
7 if(aNode)
8 var query = "<query xmlns='"+ns.info+"' node='"+aNode+"'/>";
9 else
10 var query = "<query xmlns='"+ns.info+"'/>";
11
12 return iq+query+"</iq>";
13 },
14 pubsubItems: function(aTo, aNode) {
15 return "<iq type='get' to='"+aTo+"'><pubsub xmlns='"+ns.ps+"'><items node='"+aNode+"'/></pubsub></iq>";
16 },
17 };
18
19 if (typeof module !== 'undefined')
20 module.exports = stanzas;