Wordpress formatting (not)
  • I’ve been exploring MarsEdit the past few days and I like the interface very much. However, one thing puzzles me. When I attempt to format a post, the formatting is not retained in WP.

    For example:

    When I enter the following basic code:

    test
    test

    when I publish this to WP the code is rewritten as invalid HTML both in WP (browser) and in MarsEdit.

    strongtest/strong
    emtest/em

    I have the default MarsEdit PREFERENCES/EDITING set to HTML Text.

    I have tried using RTF with similar results.

    I must be missing something really basic. I am NOT a WP expert and am new to MarsEdit.
  • Hi Grady - I can't be positive but your description has the tell-tale signs of a server configuration problem that has vexed many people over the past few years. In a nutshell the underlying HTML for your posts is getting "stripped" in a way that eliminates the brackets in the HTML formatting tags.

    Your server administrator probably needs to update the libxml and php libraries on the server:

    http://josephscott.org/archives/2009/03/conclusion-of-libxml2-issues-use-php-529-libxml2-273/

    Once the libraries are fixed on the server the bracket stripping problem should clear right up!

    Daniel
  • I tried to get my host (Fatcow) to upgrade their PHP & libxml2, but they don't really believe in upgrades, unless they are forced to.

    But there was STILL HOPE!!

    Check this out:

    "Despite the libxml2 problems having been solved by the release of PHP 5.2.9 and libxml2 2.7.3 there are still hosts out there who refuse to update their known to be broken setup. This really bummed me out, I didn’t want to include a hack to deal with this in core WordPress.

    Just as I was ready to throw in the towel and look at getting a work around into core WordPress Peter Westwood suggested a method that would allow this “fix” to work in a plugin. His idea was spot on and I wrote a small WordPress plugin, LibXML2 Fix, the next day and tested it on a WordPress install with this problem. It fixed the stripped brackets problem for XML-RPC requests, so I’ve submitted it to the plugin directory and it’s now available at http://wordpress.org/extend/plugins/libxml2-fix/.

    To be clear, the best way to fix this is to upgrade to PHP 5.2.9+ and libxml2 2.7.3+. But if you are stuck in a hosting situation where that’s not possible then the LibXML2 Fixed plugin will fix XML-RPC requests so that brackets don’t get stripped."
    Source: http://josephscott.org/archives/2009/03/wordpress-libxml2-episode-iv-a-new-plugin/
  • Glad you found the plugin. It's a real shame when servers won't update known buggy libraries, but yes, the plugin is a great backup plan!
  • Thank you @aberstan thank you for writing this up and posting the plugin solution! I just ran into the same problem at Bizland and was tearing my hair out. The plugin resolved it. My real solution will be convincing the client to move their site off Bizland servers, but in the short term this keeps the site usable from MarsEdit.
Start a New Discussion

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!