January 17, 2009 3:59 pm GMT
When Windows Live Writer messes up the HTML…
by Gary IllyesThis happened to me as soon as I installed Windows Live Writer. It came with Windows Live Mail, and sincerely I had no idea that a Microsoft program can successfully communicate with an open-source web application, neither knew about remote publishing programs, so I was very curious. Yes, I know, am ignorant. Then I installed it from the Windows Live Mail distribution as Windows Live Writer comes bundled in this package.
During install, I was told that it can’t connect to DevOracles. “AHA”, I though, this was the first error. But it also told me that I have to enable the XML-RPC publishing protocol in WordPress and that will solve my issue. So I enabled it, what could I loose.
The user interface of Windows Live Writer is extremely simple: after I’ve set up the blog’s settings, I went ahead and tried to save a draft on the blog to see how it will look like. And for my shock, this is what I saw: <skip to resolution>
p align=”center”>Some text, strong>now in bold/strong> and finally an em>emphasis/em>/p>
Well, apparently something messed up the HTML. That’s a huge problem! Immediately I tried to post to another blog on a GoDaddy server, there worked fine. So I knew that the problem is with the DevOracles server and NOT with Windows Live Writer. I tried to search on the net for some info, but all I found were posts where people complained about Windows Live Writer and how it messed up their blog or posts.
But if they would’ve knew what I knew… Let’s think a bit: the XML remote publishing protocol uses, well, some XML library to post to the blog. There has to be a working XML library else my draft wouldn’t have been saved on the blog. But my HTML has been messed up… Likely there’s either a security setting on the server set too high and it strips the HTML or there’s a bug in the XML library which is used to parse the data sent by Windows Live Writer.
What can it be? First which came into my mind is the security settings of the DevOracles servers, then that WordPress is a PHP application, which can make use of an XML library.
Step by step: I reviewed the security settings, everything seemed to be normal and there was no reference to XML. Checked.
Next step is PHP. We were using 5.2.6, at the time of this post 5.2.8 is out, so I thought as soon as I find the bug I will also upgrade PHP.
Last step: RPMs, Apache modules and PHP libraries. And what I found, made myself to feel as tiny as a flea: libXML wasn’t bundled in PHP.
So, how to fix the broken HTML issue of Windows Live Writer: You have to rebuild PHP with libXML. If you are a pro, then compile the latest PHP stable release with libxml from the command line, else make use of WHM and Easy Apache. If you’re on a hosting plan, ask your host politely to recompile PHP with libXML.
This post is published using Windows Live Writer. And I love it …
















Comments
Tell us what you're thinking...
and oh, if you want a pic to show with your comment, go get a gravatar!
If you want to use your OpenID, fill out the field labeled "Website" with the OpenID URL. The other fields may remain empty.
Note that comments are pre-moderated.