summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--inc/template.php19
-rw-r--r--lib/tpl/dokuwiki/tpl_header.php19
2 files changed, 7 insertions, 31 deletions
diff --git a/inc/template.php b/inc/template.php
index fb468d041..60e178d1a 100644
--- a/inc/template.php
+++ b/inc/template.php
@@ -1786,24 +1786,5 @@ function tpl_classes() {
return join(' ', $classes);
}
-/**
- * Create event for tools menues
- *
- * @author Anika Henke <anika@selfthinker.org>
- */
-function tpl_toolsevent($toolsname, $items, $view='main') {
- $data = array(
- 'view' => $view,
- 'items' => $items
- );
-
- $hook = 'TEMPLATE_'.strtoupper($toolsname).'_DISPLAY';
- $evt = new Doku_Event($hook, $data);
- if($evt->advise_before()){
- foreach($evt->data['items'] as $k => $html) echo $html;
- }
- $evt->advise_after();
-}
-
//Setup VIM: ex: et ts=4 :
diff --git a/lib/tpl/dokuwiki/tpl_header.php b/lib/tpl/dokuwiki/tpl_header.php
index 547dd1401..a2bfd4346 100644
--- a/lib/tpl/dokuwiki/tpl_header.php
+++ b/lib/tpl/dokuwiki/tpl_header.php
@@ -46,13 +46,10 @@ if (!defined('DOKU_INC')) die();
tpl_userinfo(); /* 'Logged in as ...' */
echo '</li>';
}
-
- tpl_toolsevent('usertools', array(
- 'admin' => tpl_action('admin', 1, 'li', 1),
- 'profile' => tpl_action('profile', 1, 'li', 1),
- 'register' => tpl_action('register', 1, 'li', 1),
- 'login' => tpl_action('login', 1, 'li', 1),
- ));
+ tpl_action('admin', 1, 'li');
+ tpl_action('profile', 1, 'li');
+ tpl_action('register', 1, 'li');
+ tpl_action('login', 1, 'li');
?>
</ul>
</div>
@@ -67,11 +64,9 @@ if (!defined('DOKU_INC')) die();
</div>
<ul>
<?php
- tpl_toolsevent('sitetools', array(
- 'recent' => tpl_action('recent', 1, 'li', 1),
- 'media' => tpl_action('media', 1, 'li', 1),
- 'index' => tpl_action('index', 1, 'li', 1),
- ));
+ tpl_action('recent', 1, 'li');
+ tpl_action('media', 1, 'li');
+ tpl_action('index', 1, 'li');
?>
</ul>
</div>