plone的简单wiki链接语法支持
collective.simplewiki的Python项目详细描述
集合.simplewiki
提供到plone站点中其他内容的简单wiki样式链接。
用(())或[[]包装的文本将呈现为链接。
换行文本用于在站点中查找内容项,即id或title。
如果内容项存在于站点上,则呈现的链接指向该项。
链接按以下顺序解析:
- 同一文件夹中的匹配ID
- 同一文件夹中的匹配标题
- 站点中其他位置的匹配ID
- 站点中其他位置的匹配标题
如果这些匹配(即,ID或标题不存在内容项),则呈现的链接是针对页(“文档”内容类型)的添加表单,标题字段预先填充由
示例
下面的示例演示如何在名为“wiki”的新本地plone站点上呈现文本,该站点包含默认的欢迎页面(id:front page,title:“welcome to plone”)
文本:
This is a link to a ((test page)). Whatever you do, don't [[try this at home]]! If in doubt, link to ((front-page)) or to ((front page)). You can also link to [[Welcome!]] or [[Welcome]] or [[Welcome to Plone]].
呈现为:
<divclass="simplewiki-container"><p>This is a link to a <ahref="http://localhost:8080/Wiki/++add++Document?form.widgets.IShortName.id=test page&form.widgets.IDublinCore.title=test page"title="Create missing content">+ test page </a>. </p><p>Whatever you do, don't <ahref="http://localhost:8080/Wiki/++add++Document?form.widgets.IShortName.id=try this at home&form.widgets.IDublinCore.title=try this at home"title="Create missing content">+ try this at home </a>! </p><p>If in doubt, link to <ahref="http://localhost:8080/Wiki/front-page"title="Welcome to Plone">Welcome to Plone </a> or to <ahref="http://localhost:8080/Wiki/++add++Document?form.widgets.IShortName.id=front page&form.widgets.IDublinCore.title=front page"title="Create missing content">+ front page </a>. </p><p>You can also link to <ahref="http://localhost:8080/Wiki/++add++Document?form.widgets.IShortName.id=Welcome!&form.widgets.IDublinCore.title=Welcome!"title="Create missing content">+ Welcome! </a> or <ahref="http://localhost:8080/Wiki/++add++Document?form.widgets.IShortName.id=Welcome&form.widgets.IDublinCore.title=Welcome"title="Create missing content">+ Welcome </a> or <ahref="http://localhost:8080/Wiki/front-page"title="Welcome to Plone">Welcome to Plone </a>. </p></div>
评论:
- 整个富文本字段用类simplewiki容器包装在<;div>;中。
- ((测试页))指向添加表单的链接。
- ((首页))指向网站默认首页的链接。
- 欢迎光临!]]和[[welcome]不按id和完整标题匹配任何内容项,但[[welcome to plone]链接到默认的首页,因为其标题完全匹配。
安装
通过将collective.simplewiki添加到构建中来安装它:
[buildout] ... eggs = collective.simplewiki
然后运行“bin/buildout”
配伍性
这个插件已经用plone 5.0和5.1进行了测试。
贡献
许可证
该项目是根据gplv2授权的。
确认
这个插件是由Wildcard Corp.开发的,由Zombie Orpheus Entertainment慷慨资助并发布给社区。
感谢僵尸奥菲斯娱乐公司的本·多宾和RPG Research的霍克·罗宾逊
更改日志
1.0.1(2017-01-06)
- 修复wiki页面的可排序标题查找 [范希姆]
1.0.0(2017-01-03)
- 文件 [金阮]
- 初次发行 [范希姆]