访问Dokuwiki渲染插件中的原始Wiki页面内容 [英] Acces the raw wiki page contents in a Dokuwiki Render Plugin

查看:250
本文介绍了访问Dokuwiki渲染插件中的原始Wiki页面内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个插件,其基本功能运行良好.如您在方法document_end()中所见,它总是返回testing.

I created a plugin and its basic functionalities are working well. It returns always testing as you can see in the method document_end().

但是我怎样才能访问普通的原始Wiki页面内容?

这是我的 rawcontent.php 文件,位于相应的插件文件夹中.

This is my rawcontent.php file in the corresponding plugin folder.

推荐答案

我明白了.在深入阅读Dokuwiki代码后,我发现了 rawWiki() .

I got it. After a deep serach in the code of Dokuwiki I discovered rawWiki().

它返回页面的原始内容,当前页面名称/id是名为$ID的全局"常量".

It returns the raw content of a page, the current page name/id is a "global" "constant" named $ID.

解决方案:

global $ID;
return rawWiki($ID);

这篇关于访问Dokuwiki渲染插件中的原始Wiki页面内容的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆