Commit 1b1859b9 authored by Rafael Monnerat's avatar Rafael Monnerat

Fix ReST transform

Add a local template due a bug into docutils, that is not able to
resolve relative url.
parent c7a4b1ef
......@@ -2,6 +2,7 @@ from Products.PortalTransforms.interfaces import ITransform
from zope.interface import implements
from reStructuredText import HTML
import sys
import os
class rest:
r"""Converts from reST to HTML.
......@@ -56,9 +57,11 @@ class rest:
input_encoding = kwargs.get('input_encoding', encoding)
output_encoding = kwargs.get('output_encoding', encoding)
language = kwargs.get('language', 'en')
warnings = kwargs.get('warnings', None)
warnings = kwargs.get('warnings', None)
rest_template = os.path.join(os.path.dirname(__file__), 'rest.template')
settings = {'documentclass': '',
'traceback': 1,
'template' : rest_template
}
html = HTML(orig,
report_level=2,
......
%(head_prefix)s
%(head)s
%(stylesheet)s
%(body_prefix)s
%(body_pre_docinfo)s
%(docinfo)s
%(body)s
%(body_suffix)s
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment