Toolbar buttons and component options

We already have the New, Edit, and Options buttons showing in our component, but there are quite a few more standard buttons that users expect to see in a component, such as Publish, Unpublish, Archive, Trash, and Help.

Open the file /administrator/components/com_folio/views/folios/view.html.php, and make the following changes:

<?php defined('_JEXEC') or die; class FolioViewFolios extends JViewLegacy { protected $items; protected $state; public function display($tpl = null) { $this->items = $this->get('Items'); $this->state = $this->get('State'); if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode("\n", $errors)); return false; } $this->addToolbar(); parent::display($tpl); } protected ...

Get Learning Joomla! 3 Extension Development - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.