DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:toucher2

toucher2 Plugin

Compatible with DokuWiki

  • 2024-02-06 "Kaos" yes
  • 2023-04-04 "Jack Jackrum" yes
  • 2022-07-31 "Igor" yes
  • 2020-07-29 "Hogfather" yes

plugin Touch config file after page edit

Last updated on
2024-07-28
Provides
Action
Repository
Source

Similar to stale, toucher

Tagged with admin, config, touch

Installation

Warning: This will touch the config file every time a page is saved, in order to invalidate the cache. This makes this plugin only suitable for wikis with a low update threshold.

I use this because I use IndexMenu, which doesn't seem to always update when adding new pages. I update my wiki (which I use as an open blog) maybe a couple of times a week. If your wiki updates more frequently, it can have a performnce impact.

Search and install the plugin using the Extension Manager. Refer to Plugins on how to install plugins manually.

Examples/Usage

In the admin/configuration options, there are two options:

  1. Allow toucher plugin only for admins (superusers)
  2. Enable for page saves (if unset, touch is only available from admin menu)

When a user creates/updates a page, the config file is touched which invalidates the cache. This action is limited to when the user is an admin or manager. Enabling the first option limits this action to admins only.

When the second option is enabled, the action takes place during page saves and page creation. If this option is unset, the plugin only touches the config file when the Touch configuration files option is selected from the Admin menu. The default for the second option is enabled for backwards compatibility with previous versions of this plugin.

When unset, the second option effectively disables the plugin except from the Admin menu.

This plugin does NOT touch the config file when a normal user saves/updates a page.

Development

I took the code from the original toucher plugin, which is identified as dead, fixed a long-standing bug and then hacked the code so it touches the config file whenever a superuser (or manager when checkbox unset) saves a page.

The stale plugin may be what you are looking for.

Changelog

Known Bugs and Issues

none

ToDo/Wish List

none

FAQ

plugin/toucher2.txt · Last modified: 2024-07-28 15:08 by Zen

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki