CoreFiles by mySites.guru
packageinstaller.php59 lines, 1,409 bytes, from Joomla_4.3.1-Stable-Full_Package.zip
Raw History Compare with 4.3.0
md5
3d1db3eae4182cc928826e3b4983d09b
sha1
11fe4c28d54755416e07f6eba8d22013023fe93d
sha256
e72085219f1cfca1e64f03a1b8746b18e07b5279318a309396c9ac3b5973f6b9
<?php

/**
 * @package     Joomla.Plugin
 * @subpackage  Installer.packageInstaller
 *
 * @copyright   (C) 2016 Open Source Matters, Inc. <https://www.joomla.org>
 * @license     GNU General Public License version 2 or later; see LICENSE.txt

 * @phpcs:disable PSR1.Classes.ClassDeclaration.MissingNamespace
 */

use Joomla\CMS\Language\Text;
use Joomla\CMS\Plugin\CMSPlugin;
use Joomla\CMS\Plugin\PluginHelper;

// phpcs:disable PSR1.Files.SideEffects
\defined('_JEXEC') or die;
// phpcs:enable PSR1.Files.SideEffects

/**
 * PackageInstaller Plugin.
 *
 * @since  3.6.0
 */
class PlgInstallerPackageInstaller extends CMSPlugin
{
    /**
     * Application object
     *
     * @var    \Joomla\CMS\Application\CMSApplication
     * @since  4.0.0
     */
    protected $app;

    /**
     * Textfield or Form of the Plugin.
     *
     * @return  array  Returns an array with the tab information
     *
     * @since   3.6.0
     */
    public function onInstallerAddInstallationTab()
    {
        // Load language files
        $this->loadLanguage();

        $tab            = [];
        $tab['name']    = 'package';
        $tab['label']   = Text::_('PLG_INSTALLER_PACKAGEINSTALLER_UPLOAD_PACKAGE_FILE');

        // Render the input
        ob_start();
        include PluginHelper::getLayoutPath('installer', 'packageinstaller');
        $tab['content'] = ob_get_clean();

        return $tab;
    }
}

The same content is in 22 releases, Joomla 4.2.7-rc1 to 4.3.4. See them all, or every version of this file.