AJAX XML-RPC Client

JavaScript XML-RPC client that communicates with XMLHttpRequest request. Both the arguments passed and the return variable are processed as JavaScript objects.
Download

How to use it:

var request = new XmlRpcRequest(URL, XML-RPC method);
request.addParam(“username”);
request.addParam(“pass”);
request.addListener(listenerObj); //listener on the connection
request.send();

The Listener should implement two methods:

/* Callback function, passed return variable as a JS Obj. */
Listener.prototype.successCallback = function (xmlRpcResponseObj, jsParsedObj) {
}

/* Callback error function, passed error as string. */
Listener.prototype.errorCallback = function (faultCode, faultString) {

if(“undefined” == typeof faultCode) {
//Server did not return any results
}
}

Download

2 thoughts on “AJAX XML-RPC Client

  1. Pingback: AJAX XML-RPC Client « Danilo Ercoli's Blog « 技術者派遣の技術日誌ブログ

  2. Pingback: 2010 in review | Danilo Ercoli

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s