You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

30 lines
664 B

  1. <?php
  2. namespace dokuwiki\Menu\Item;
  3. /**
  4. * Class Back
  5. *
  6. * Navigates back up one namepspace. This is currently not used in any menu. Templates
  7. * would need to add this item manually.
  8. */
  9. class Back extends AbstractItem
  10. {
  11. /** @inheritdoc */
  12. public function __construct()
  13. {
  14. global $ID;
  15. parent::__construct();
  16. $parent = tpl_getparent($ID);
  17. if (!$parent) {
  18. throw new \RuntimeException("No parent for back action");
  19. }
  20. $this->id = $parent;
  21. $this->params = ['do' => ''];
  22. $this->accesskey = 'b';
  23. $this->svg = DOKU_INC . 'lib/images/menu/12-back_arrow-left.svg';
  24. }
  25. }