Докувики: отключение управления версиями в Докувики - PullRequest
0 голосов
/ 17 июня 2011

Мне нужна помощь в отношении докувиков. Я хочу удалить версии из вики.Любой совет наша помощь будет высоко оценена.Заранее спасибо, я изучил этот код, но до сих пор не получил никакой идеи

`класс 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;
}`

1 Ответ

1 голос
/ 17 июня 2011

Поиск функции saveOldRevision () в inc / common.php.

Btw. Я бы предложил задать такие вопросы в официальном форуме / списке рассылки. Там вы найдете людей, которые знают исходный код.

...