Created
April 22, 2009 05:43
-
-
Save whoahbot/99611 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function sendMsg(message) { | |
try { | |
var aMsg = new JSJaCMessage(); | |
aMsg.setTo(new JSJaCJID("#[email protected]/whoahbot")); | |
aMsg.setType('groupchat'); | |
aMsg.setBody(message); | |
con.send(aMsg); | |
} catch (e) { | |
$('#chat').html("<div class='msg error''>Error: "+ e.message +"</div>"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment