xref: /dokuwiki/inc/Menu/Item/Back.php (revision 3e2fa388693f117b05e78c833043887bdae5578b)
1<?php
2
3namespace dokuwiki\Menu\Item;
4
5class Back extends AbstractItem {
6
7    /** @inheritdoc */
8    public function __construct() {
9        global $ID;
10        parent::__construct();
11
12        $parent = tpl_getparent($ID);
13        if(!$parent) {
14            throw new \RuntimeException("No parent for back action");
15        }
16
17        $this->id = $parent;
18        $this->params = array('do' => '');
19        $this->accesskey = 'b';
20    }
21
22}
23