Enable Markdown, Textile and ReStructured Text Support
Purpose
Your content authors want to use the text markup formats Markdown and/or Textile, rather than Plone's WYSYWIG editors. Fine. Here's how to give them what they want.
Prerequisities
This was tested on:
- Plone 3.2
- CMF 2.1.2
- Zope (Zope 2.10.6-final, python 2.4.5, linux2)
- Python 2.4.5 (#1, Mar 6 2009, 11:25:56) [GCC 4.1.2 20071124 (Red Hat 4.1.2-42)]
- PIL 1.1.6
Step by step
Installation
Install the Markdown and textile eggs. Note that the textile 2.0.1 is the last textile version compatible with Python 2.4, and therefore with Plone 3.x.
If you're using buildout, add this to your buildout.cfg file:
- NOTE: ReStructured text does not need additional eggs.
[buildout] ... eggs += Markdown textile==2.0.1
- Re-run buildout.
Configuration through the web
- In your site's Control Panel, navigate to Markup (/@@markup-controlpanel).
- Select:
- Click Save.
Configuration using GenericSetup
You can set these options in the propertiestool.xml file in a policy product. Something like this:
<?xml version="1.0"?>
<object name="portal_properties" meta_type="Plone Properties Tool">
<object name="site_properties" meta_type="Plone Property Sheet">
<property name="forbidden_contenttypes" remove="true" />
<property name="forbidden_contenttypes" type="lines">
<element value="text/structured"/>
<element value="text/x-rst"/>
<element value="text/plain"/>
<element value="text/plain-pre"/>
<element value="text/x-python"/>
<element value="text/x-web-intelligent"/>
</property>
</object>
</object>
Further information
One more tricky bit of information:
For users to enter content in a markup language, they will need to click "Edit without the visual editor" which is below the text content area. Only then will the text-format dropdown be enabled.
