powered by Jive Software

Problem about create an new account from Jabber server!

I use the code below to register a new account from the jabber server:

import org.jivesoftware.xiff.data.Message;

import org.jivesoftware.xiff.core.XMPPConnection;

import org.jivesoftware.xiff.im.Roster;

var connection = new XMPPConnection();

connection.server = “pandahall.jxs.cn”;

var username:String = “heyinna.163.coma7web”;

var email:String = "heyinna@163.com";

var password:String = “0”;

var regInfo = new Object();

regInfo = ;

//var loginAfter:Boolean = true;

eventHandler = new Object();

eventHandler.handleEvent = function(eventObj)

{

switch (eventObj.type)

{

case “outgoingData”:

trace( "SENT: " + eventObj.data );

break;

case “incomingData”:

trace( "RECEIVED: " + eventObj.data );

break

case “connection” :

//send the registration

connection.getRegistrationFields();

trace("----


login after")

break;

case “registrationFields” :

trace(“REG FIELDS”);

//send the register field

connection.sendRegistrationFields(regInfo);

break;

case “registrationSuccess” :

trace(“REGISTATION SUCCESS”);

break;

}

}

connection.addEventListener( “outgoingData”, eventHandler );

connection.addEventListener( “incomingData”, eventHandler );

connection.addEventListener(“connection”, eventHandler);

connection.addEventListener(“registrationFields”, eventHandler);

connection.addEventListener(“registrationSuccess”, eventHandler);

connection.connect(“flash”);

when i test the code in the flashmx i find the error below:

here is the iq i send to the server :

SENT:

can any one tell me what’'s wrong, Thanks a lo!.

I have sovled the question myselft.

Can you please share what you did for those of us having the same problem?