- md5
- 1ba1b72f5e5f7bd55e8ba804760a411f
- sha1
- 5fa3452c47926b43d67b3994702093b35347efcd
- sha256
- 59143801eff8487ad62c7471dbbf145e7e41a903bdeb30054cb6828c932858bc
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
<?php
/**
* @version $Id: view.html.php 20196 2011-01-09 02:40:25Z ian $
* @copyright Copyright (C) 2005 - 2011 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
// No direct access.
defined('_JEXEC') or die;
jimport('joomla.application.component.view');
/**
* View class for a list of plugins.
*
* @package Joomla.Administrator
* @subpackage Plugins
* @since 1.5
*/
class PluginsViewPlugins extends JView
{
protected $items;
protected $pagination;
protected $state;
/**
* Display the view
*/
public function display($tpl = null)
{
$this->items = $this->get('Items');
$this->pagination = $this->get('Pagination');
$this->state = $this->get('State');
// Check for errors.
if (count($errors = $this->get('Errors'))) {
JError::raiseError(500, implode("\n", $errors));
return false;
}
parent::display($tpl);
$this->addToolbar();
}
/**
* Add the page title and toolbar.
*
* @since 1.6
*/
protected function addToolbar()
{
$state = $this->get('State');
$canDo = PluginsHelper::getActions();
JToolBarHelper::title(JText::_('COM_PLUGINS_MANAGER_PLUGINS'), 'plugin');
if ($canDo->get('core.edit')) {
JToolBarHelper::editList('plugin.edit', 'JTOOLBAR_EDIT');
}
if ($canDo->get('core.edit.state')) {
JToolBarHelper::divider();
JToolBarHelper::custom('plugins.publish', 'publish.png', 'publish_f2.png', 'JTOOLBAR_ENABLE', true);
JToolBarHelper::custom('plugins.unpublish', 'unpublish.png', 'unpublish_f2.png', 'JTOOLBAR_DISABLE', true);
JToolBarHelper::divider();
JToolBarHelper::custom('plugins.checkin', 'checkin.png', 'checkin_f2.png', 'JTOOLBAR_CHECKIN', true);
}
if ($canDo->get('core.admin')) {
JToolBarHelper::divider();
JToolBarHelper::preferences('com_plugins');
}
JToolBarHelper::divider();
JToolBarHelper::help('JHELP_EXTENSIONS_PLUGIN_MANAGER');
}
}
The same content is in 2 releases, Joomla 1.6.0 to 1.6.1. See them all, or every version of this file.