Update On libxml2 Issues

4 Mar 2009 @ 2:38pm : Conclusion of libxml2 Issues – Use PHP 5.2.9 & libxml2 2.7.3

17 Mar 2009 @ 3:05pm : WordPress & libxml2 Episode IV: A New Plugin

At the end of December I detailed problems people were seeing with WordPress, XML-RPC and libxml2. I’ve got good news, both PHP and libxml2 have been updated to fix the issue. You can send your many thanks to Rob Richards who addressed this a couple of weeks ago with updates to ext/xml (PHP) and libxml2.

You’ll need version 2.7.3 or higher of libxml2 and 5.2.9 (not released yet) of PHP. I’ve tried this out on a system that had libxml2 2.7.1 with known problems and then upgraded it to 2.7.3 and a nightly build of PHP. I’m not sure if we’ll see 5.3 or 5.2.9 as the next PHP release, so I tested snapshots from both branches with libxml2 2.7.3 and confirmed that they both work.

After this all started there were a few patches making the rounds that basically changed the encoding for the HTML entities that were having problems. I’ve done some light testing of those for the XML-RPC case and found that they do appear to work. I’m not sure yet about adding that to WordPress, especially now that we’ve got viable fixes at the PHP and libxml2 level. I think if we see a PHP release soon that includes this fix then it’s best to encourage people to upgrade to address the problem.


  1. Joeseph,

    Thanks for the info. I’m wondering about something though.

    According to my php test info data ( “phpinfo()” ) my host is running PHP 5.2.8 and libxml 2.7.2. I use the latest version of Windows Live Writer (14.0.8064.206) for writing/editing my blog posts and WP’s TinyMCE occasionally and my blog is running on WordPress 2.7.1. Currently I’m not having any problems at all with the left angle bracket being stripped out so here’s what I’m wondering (excuse the ignorance on my part–not a server savvy).

    Is there actually a libxml and a libxml2 or is my host just dropping the “2” at the end for some reason. I’m guessing that the php test report is actually referring to “libxml2” 2.7.2 in it’s report and not “libxml” 2.7.2.

    Have you had a chance to test this combination of PHP 5.2.8 and libxml2 2.7.2 yet? I’m interested to see if some folks are having a problem with this combination and other folks like myself are not.

  2. I’m not entirely sure what the story is with the libxml naming styles. Sometimes it gets referred to as libxml (like in the case of phpinfo() output), from what I can tell though all libxml 2.x versions are libxml2.

  3. Thanks for the reply Joeseph. At least libxml/libxml2 is following true to form just like everything involving computers and computer technology. πŸ˜€

  4. My ISP reports that their version of lib2xml is version libxml2-2.6.26- (it may be falsely reported) but I still have this problem of stripping left brackets. Your solution of upgrading to version 2.7.3 is just impractical for the thousands of WordPress users like me who use hosted ISP services. Apart from waiting ages until something changes, what do folks like me do to post using any of the third-party software like WLW

  5. Note that in order for new versions to work both libxml2 and PHP have to be upgraded. Only doing one or the other is not enough.

    I’m not thrilled with the current situation. On the one hand it’s pretty sad to see service providers willing to use known broken versions of software. My general recommendation is to switch to services that actually care enough about their paying customers to use upgrade software as needed.

    In the meantime I’m sympathetic to folks who are at the mercy of others to deal with this problem. As much as I’d rather not, this week I’m going to look at adding the libxml2 workaround to WordPress -trunk with the idea of making it part of the 2.8 release. I’m not thrilled at the prospect of having to do this, but may not be left with much choice.

Leave a Reply

Your email address will not be published. Required fields are marked *

© 2019 Joseph Scott

Theme by Anders NorénUp ↑