As some of you may have noticed over the last few weeks as I found time I was posting test posts to the blog after several of the most recent "real" posts got FUBAR’ed after posting and I wasn’t bright enough to go back and look at the post right away to validate that it had indeed posted properly. This resulted in completely confusing posts that required people to email me to say, hey dude, your blog is all dorked up, you might want to check into that.
Anyway I worked out the problem… finally. Certainly it wasn’t as easy as I thought it should be. Well the fix itself was simple, finding it was another matter entirely. I just didn’t seem to hit on the right combination of search words that didn’t result in post where someone was describing the issue and some bright person was telling them they didn’t know what they were doing.
The issue I was seeing was that HTML tags in Windows Live Writer (WLW) were getting half way sort of stripped. Specifically the opening and closing, ummm brackets? braces? The less than symbol (<) and the greater than symbol (>). The most common issue was the paragraph tag was getting changed from <p> to p and the end paragraph was changing from </p> to /p. Obviously that plays a bit of havoc with the formatting when a browser is trying to render the page.
I wanted to post this so hopefully all of the other people I found out asking the same questions I was asking could get the solution, which is remarkably easy.
So without further adieu… The issue with the partially stripped HTML tags is a bug in libxml2. Specifically using anything less than PHP 5.2.9+ with libxml2 2.7.3+ is susceptible. The fix is to install a plugin into WordPress called LibXML2 Fix which you can get from your plugins menu or look here -> http://wordpress.org/extend/plugins/libxml2-fix/.
For more detailed info see http://core.trac.wordpress.org/ticket/7771
Oh… How do you know what version of PHP and LibXML2 you are running you ask? Well you can ask your admins or you can look for an info page on your provider’s web site. But, as I found with my provider, they neglected to update their page so I found you can add the following PHP script to your website and just run it by calling it from a browser and it will tell you all about your PHP Installation.
<title> PHP Info</title>
That will give you something that looks like:
which will go on and on with info for you. The main things you need to look at are the version of PHP
and the version of libxml2.
As soon as I applied the libxml2 fix plugin I was able to upload posts from Windows Live Writer with no issue.
I hope this helps someone else. 🙂
 The use of the word real does not in any way shape or form imply quality, suitability, accuracy, or safety to use in any environment whether test, production or otherwise.