The blogging bundle works with WordPress 2.0. It probably does not work with 1.5.

Uploading Images

If uploading of images doesn’t work, be sure that:

  1. Your WordPress system is properly configured to allow uploads (should be enabled by default, but double check)
  2. Your web server has write access to the upload directory.

Specifying Date Created

There has been a few problems related to correct dates. This comes from the fact that the dateCreated argument (in the XML-RPC protocol) has no time zone info, and until WordPress 2.2 it was interpreted mostly as server time.

Starting with WordPress 2.2 this field is GMT and dates should be offset correctly.

Unfortunately WordPress 2.2.1 introduced a Z in the date format which breaks Ruby 1.8.2’s XML-RPC parser — so if you use WordPress 2.2.1 then you need to update your installed Ruby version. If you have MacPorts installed then you can run sudo port install ruby and update your PATH. See RubyVersionIssues for help with that.

Even more unfortunately, the next version of WordPress will revert its date handling to before 2.2 and so, after that release, dates will again use the wrong offset.

Update: Starting with revision 9600 of the blogging bundle, we include GMT date headers (a WordPress extension).

Wrong Size Exception

Some users get an error like the following:

Received exception:Wrong size. Was 1275, should be <unknown>

This seems to be because WordPress does not send a length header with its reply, but Ruby’s XML-RPC library expects it.

A workaround is to comment line 547-552 in /usr/lib/ruby/1.8/xmlrpc/client.rb. If you do not have the stock Ruby (from Mac OS 10.4.8) then the line numbers may differ from what’s stated above. The following lines are those you want to disable:

expected = resp["Content-Length"] || "<unknown>"
if data.nil? or data.size == 0 
  raise "Wrong size. Was #{data.size}, should be #{expected}" 
elsif expected.to_i != data.size and resp["Transfer-Encoding"].nil?
  raise "Wrong size. Was #{data.size}, should be #{expected}"

Note: you may have to change /user/local/lib/ruby/1.8/xmlrpc/client.rb if you are not using the default install of ruby that is bundled with OS X. The starting line number for this file is 558.

Server accepts POST requests only

If you get an error like server accepts POST requests only then that’s caused by a PHP 5.2.2 bug.

See this article for a workaround.

Enabling Full Logging (XML-RPC)

Sometimes it is necessary to enable full logging (server side) to debug a problem.

To do this, edit xmlrpc.php (on your server). Search for this line:

$xmlrpc_logging = 0;

And change it so that it sets the variable to 1 instead of 0.

A few lines down you will find:

if ($xmlrpc_logging) {
    $fp = fopen("../xmlrpc.log","a+");

This has the log file placed in the parent folder (i.e. the one containing your blog), if the process that runs your blog (e.g. apache) can’t write to this folder, you will need to alter the path, make it so that apache can write to the parent folder, or create the file and make it world-writable.

For the latter (assuming we are in the blog directory) do:

touch ../xmlrpc.log
chmod a+w ../xmlrpc.log

Friendly links:

beautiful wordpress free themes