【发布时间】:2013-04-22 15:49:39
【问题描述】:
我想用 reStructuredText 和 rst2html5 编写一个 2 列的网站 (html)。
我试过这样
.. container:: right
Right text
.. container:: left
Left text
而且效果很好(使用 css “float”)。
但是,rst2html5 无法编译 .rst,其中包含容器指令中带有消息 (SEVERE/4) Unexpected section title or transition..
.. container:: right
========
Section1
========
Right text
.. container:: left
Left text
我猜/认为 rst2html5 行为对于 rst 规范是完全有效的。
我想像这样使用 rst2html5 从 .rst 获取 .html。
<div class="right">
<h1>Section1</h1>
<p>Right text</p>
</div>
<div class="left">
<p>Left text</p>
</div>
是否允许在容器或类似内容中包含部分?(我认为这是不允许的,对吗?) 要么 如何从 .rst(使用 rst2html5)获得与上述类似的 html 输出?
我阅读了this 线程,但无法获得 2 列 html。
任何 cmets 将不胜感激。提前致谢。
【问题讨论】:
标签: python html restructuredtext