Markdown and Wordpress 2.0

WordPress 2.0 has a new “rich” visual HTML editor which generate HTML markup directly. This editor should work fine alongside Markdown, but Markdown-formatted text won’t work in this new editor. You can tell the rich editor is active when there are icons for bold, italic and other functions above the text editor. To edit Markdown text, you need to deactivate the rich editor. Here’s how.

There are two places you can deactivate the editor. Each user can activate or deactivate it from the “User” section of the administration interface: uncheck checkbox “Use the visual rich editor when writing” at the bottom of the page. You can deactivate the rich editor for new users from Option > Writing > “Users should use the visual rich editor by default” checkbox.

If you want to use the rich editor again, no problem, you can reactivate it and use it at anytime. But then you should make sure the rich editor is disabled before editing a Markdown-formatted post.

Also note that WordPress 2.0 official distribution does no longer include the Markdown plugin. You’ll have to get it from the PHP Markdown project page.


Comments

Matt

Thanks for this information.

Darryl

So in other words I can never edit my markdown formatted posts again unless I remember this little trick?

Michel Fortin

As you said. If you haven’t deactivated the “rich” editor, to edit older Markdown-formatted posts you’ll need to reformat your post using the new editor instead of Markdown. Or you can remember to deactivate the “rich” editor.

Maybe an updated version of Text Control for WordPress 2.0 will see the day and solve that issue. Until then this “trick” is the best thing I can give you.

Michel Fortin

Emil, you can’t get back the original text because Markdown to HTML conversion is lossy: there are two syntaxes for headers, many more for links, and they produce the same HTML output. But you can try HTML2Text — a Python script by Aaron Swartz — if you want to see something close.

Emil Kampp

Is there a call-back function in the markdown.php ? That converts the <h1>head</h1> back to #head ??


  • © 2003–2017 Michel Fortin.