Today my friend Rafał left a comment on my previous attempt at getting Joomla to work with Windows Live Writer. He gave me a link to the very post I had linked to myself :D Even so I tried again, and found another interesting post on the MYGUIDE blog. In that post I read about Fiddler, a very nice application for eavesdropping on whatever any application sends to a server. Krzysiek Sopyła demonstrated it at one of the OLMUG meetings; I had not had a chance to play with it, and now the chance presented itself.

I listened in on the conversation between WLW and my Joomla, and this is what I saw:

8b
<br />
<b>Notice<!--b>:  Undefined index:  more_text in <b>/.../www/plugins/xmlrpc/metaweblog.php<!--b> on line <b>213<!--b><br />

8e
<br />
<b>Notice<!--b>:  Undefined index:  mt_text_more in <b>/.../www/plugins/xmlrpc/metaweblog.php<!--b> on line <b>217<!--b><br />

87
<br />
<b>Notice<!--b>:  Undefined variable: row in <b>/.../www/plugins/xmlrpc/metaweblog.php<!--b> on line <b>261<!--b><br />

94
<br />
<b>Notice<!--b>:  Trying to get property of non-object in <b>/.../www/plugins/xmlrpc/metaweblog.php<!--b> on line <b>261<!--b><br />

80
xml version="1.0"?>
<methodResponse>
<params>
<param>
<value><string>341<!--string><!--value>
<!--param>
<!--params>
<!--methodResponse>
0

That made everything clear. Metaweblog was a little "rough around the edges", and wherever warnings were not switched off on the server, extra messages appeared and broke the structure of the XML. Strictly speaking I ought to have warnings switched off (so that if something goes wrong a visitor does not get to read more or less interesting messages), but I often use my site as a testing ground, and that is why things are as they are.

I fixed a few lines in metaweblog.php and now I can write in WLW. Unfortunately automatic image upload does not work (I did set the FTP options in WLW), nor does downloading the theme or all of the posts straight from the site. Getting that working would mean fixing another dozen or so lines.

P.S.

I also recommend the WLW plugin called Dynamic Template. It lets you add templates of your own, for instance one that splits an article into an intro and the rest, with a "Read more..." break in between :) Unfortunately, when you edit the post again the "Read more" turns into a comment and no longer does its job - ah, interoperability, or rather the lack of it...