XML-RPC Response Parsing Failed

May 31st, 2007

We are currently living through a minor sort of plague when it comes to remote editing of PHP-based blogs. As web hosting companies upgrade to PHP 5.2.2, some of you may notice that your attempts to publish or edit entries with MarsEdit yields an error dialog with a cryptic error “XML-Response Parsing Failed.” This bug is caused by a bug in PHP that causes blogging systems to return blank responses instead of the expected XML result.

WordPress was quick to work around the bug, and included the change in their 2.2 release. Unfortunately the 2.2 release also added a minor time zone bug, so we’ll be looking forward to 2.2.1 for complete normalcy.

If you want to fix the bug yourself on whatever system you’re using, the workaround seems to be essentially adding this line to the top of your XML-RPC php file (after the “<?php”):

$HTTP_RAW_POST_DATA = file_get_contents( 'php://input' );

Nasty bug. Easy workaround. Hope this passes soon. I get new support inquiries every time DreamHost updates a batch of servers :)

(Big thanks to “mph” for first bringing this issue to my attention in the MarsEdit Forums)

2 Responses to “XML-RPC Response Parsing Failed”

  1. enefekt Says:

    For real, that sucks. If you get any Nucleus CMS users where this still isn’t working, I had success with just grabbing and swapping in the newest xmlrpc libs they use.

    They have been updated with fixes to bugs related to these security updates, you can get them here:
    http://phpxmlrpc.sourceforge.net/

  2. Tom Harrington Says:

    This is the same problem (well, one of the problems) I ran into with Pair a couple of weeks ago. I gather that it’s not such a good idea to rely on $HTTP_RAW_POST_DATA being set anyway, but it sucks when working code suddenly breaks without explanation. I mistakenly assumed Pair had changed their PHP configuration.

Comments are closed.

Follow the Conversation

Stay up-to-date by subscribing to the Comments RSS Feed for this entry.