View filters and search
In a Joomla! 3 component, there is usually some view filters that allow you to limit the items shown, for instance, only showing items where the status
is published
. Besides the status
filter, we usually expect to see search in title, sort table by, and ordering.
Sidebar filters
We will start off by adding the sidebar with a status
filter. Edit the file /administrator/components/com_folio/views/folios/view.html.php
.
<?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)); ...
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.