dokuwiki:在 dokuwiki 中禁用版本控制
我需要有关 dokuwiki 的帮助 我想从 wiki 中删除版本控制。任何提示我们的帮助将受到高度赞赏。 提前致谢 我已经研究过这段代码,但到目前为止还没有任何想法
`class cache_renderer extends cache_parser { 函数_useCache() { 全局 $conf;
if (!parent::_useCache()) return false;
if (!isset($this->page)) {
return true;
}
// check current link existence is consistent with cache version
// first check the purgefile
// - if the cache is more recent than the purgefile we know no links can have been updated
if ($this->_time >= @filemtime($conf['cachedir'].'/purgefile')) {
return true;
}
// for wiki pages, check metadata dependencies
$metadata = p_get_metadata($this->page);
if (!isset($metadata['relation']['references']) ||
empty($metadata['relation']['references'])) {
return true;
}
foreach ($metadata['relation']['references'] as $id => $exists) {
if ($exists != page_exists($id,'',false)) return false;
}
return true;
}`
i need help regarding dokuwiki
i want to remove versioning from wiki. any tip our help will be highly appreciated.
Thanks in advance
I have looked into this code but so far didnt get any idea
`class cache_renderer extends cache_parser {
function _useCache() {
global $conf;
if (!parent::_useCache()) return false;
if (!isset($this->page)) {
return true;
}
// check current link existence is consistent with cache version
// first check the purgefile
// - if the cache is more recent than the purgefile we know no links can have been updated
if ($this->_time >= @filemtime($conf['cachedir'].'/purgefile')) {
return true;
}
// for wiki pages, check metadata dependencies
$metadata = p_get_metadata($this->page);
if (!isset($metadata['relation']['references']) ||
empty($metadata['relation']['references'])) {
return true;
}
foreach ($metadata['relation']['references'] as $id => $exists) {
if ($exists != page_exists($id,'',false)) return false;
}
return true;
}`
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在 inc/common.php 中搜索函数 saveOldRevision()。
顺便提一句。我建议在官方论坛/邮件列表中提出此类问题。在那里你会找到了解源代码的人。
Search for the function saveOldRevision() in inc/common.php.
Btw. I would suggest to ask such questions in the official forum/mailinglist. There you'll find the people who know the sourcecode.