Formatting for LightPress

jerome, Sunday 22 May 2005 23:39:20 PST

Post formatting is fairly basic in LightPress and caters to the "what you type is what you get" crowd. But it's easy to expand LP's formatting abilities by using the PreFormatted 2.0 plugin.

Normally WordPress formats posts only when they're displayed (wasting rendering time and server capacity in the process). The PreFormatted plugin rearranges formatting plugins like Markdown and Textile so that they're only active in the backend, saving a formatted copy of the post to the database. If you use this plugin in the WordPress backend then the formatted data is available to your LightPress site.

Step-by-step:

  1. Install PreFormatted 2.0 and activate it from the WordPress admin panel

  2. Install the PreFormatted plugin for LightPress (copy to your

    /plugins

    directory and add it to the list of plugins in

    config.php

    ). This simple plugin will be included in the next LightPress release.

  3. Activate your favourite WordPress formatting plugin. If none are activated, then WordPress' default formatting will be used.

  4. Every post saved after PreFormatted 2.0 was activated will appear fully formatted in LightPress. You can re-save old posts to get the formatted version to show up in LightPress.

Readers' Comments

  1. Ramin

    What I really wanna know is, how do you tell WP to stop putting in those P tags all over the place. It gets really annoying when I’m trying to put in html code in my posts and WP decides to put those P tags everywhere. The only solution I’ve come up with so far is to remove all extra line breaks when I don’t want the P tags. Is there a way to tell WP to ignore formatting all together and allow me to enter my own html formatting?

  2. jerome

    Ramin,
    There are a couple of issues to consider here. First off, LightPress will do the same thing to you: if you’re not using PreFormatted then all blank lines will be converted to paragraph breaks.

    If you’re using PreFormatted, you can use a WP plugin to get rid of this behaviour: disable-wpautop.

    You may also want to disable wp-texturize as well (it’s what creates smart quotes and encodes oddball characters).

  3. jerome

    I see that Ludo has just released 1.0.4 on SourceForge. The PreFormatted plugin is now included with the source.

  4. ludo

    And running on this site :)