1<?php 2// must be run within Dokuwiki 3if (!defined('DOKU_INC')) die(); 4 5class admin_plugin_tagging extends DokuWiki_Admin_Plugin { 6 7 private $hlp; 8 private $message; 9 10 function forAdminOnly() { return false; } 11 12 function handle() { 13 $this->hlp = plugin_load('helper', 'tagging'); 14 15 if ($_SERVER['REQUEST_METHOD'] === 'POST') { 16 if (checkSecurityToken()) { 17 global $INPUT; 18 $input = $INPUT->post->arr('action'); 19 if (isset($input['rename'])) { 20 $this->message = $this->hlp->renameTag($input['formerTagName'], $input['newTagName']); 21 } 22 } 23 } 24 } 25 26 function html() { 27 global $ID; 28 $tags = $this->hlp->getAllTags(); 29 include dirname(__FILE__) . '/admin_tpl.php'; 30 } 31 32} 33