Skip to content

A simple JavaScript XML-RPC Library for WordPress. It communicates with the server using XMLHttpRequest requests.

License

Notifications You must be signed in to change notification settings

staypufd/JS-XML-RPC-lib-for-WordPress

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WordPress XML-RPC Library that communicates with XMLHttpRequest requests. 
Both the arguments passed and the return variable are processed as JavaScript objects.

The following WordPress XMLRPC methods (http://codex.wordpress.org/XML-RPC_wp) are available within the lib

wp.getUsersBlogs
wp.getCommentCount
wp.deleteComment
wp.editComment
wp.newComment
wp.getCommentStatusList
wp.getComment
wp.getComments
wp.getPage
wp.getOptions
wp.getPosts
metaWeblog.newPost

How to use it:

var connection = new AddBlogConn("username" , "password", "xmlrpc endpoint URL");
connection.addListener(new AddBlogsListener());
connection.startConn();

The Listener should implement at least these three methods:
function AddBlogsListener(){
}
AddBlogsListener.prototype.connRequestError = function(errorMsg){
EW.LogSystem.error("AddBlogsListener.connRequestError");
}
AddBlogsListener.prototype.connRequestStopped = function(){
EW.LogSystem.debug("AddBlogsListener.connRequestStopped");
}

AddBlogsListener.prototype.connRequestCompleted = function(userBlogs){
EW.LogSystem.debug("AddBlogsListener.connRequestCompleted");
}

About

A simple JavaScript XML-RPC Library for WordPress. It communicates with the server using XMLHttpRequest requests.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%