CoreFiles by mySites.guru
Dispatcher.php46 lines, 1,125 bytes, from Joomla_5.2.2-Stable-Full_Package.zip
Raw History Compare with 5.2.1
md5
b600e7246fb916cca676a548416a078b
sha1
28e4aa1562d12675e31879db690bd5d46bb7d449
sha256
b62945fe9fb4d1a54c4673c9af7469758e146e9f1616a2accd52f0916a296ff8
<?php

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

namespace Joomla\Module\Footer\Site\Dispatcher;

use Joomla\CMS\Dispatcher\AbstractModuleDispatcher;
use Joomla\CMS\HTML\HTMLHelper;

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

/**
 * Dispatcher class for mod_footer
 *
 * @since  4.4.0
 */
class Dispatcher extends AbstractModuleDispatcher
{
    /**
     * Returns the layout data.
     *
     * @return  array
     *
     * @since   4.4.0
     */
    protected function getLayoutData(): array
    {
        $data = parent::getLayoutData();

        $lineOne = $this->getApplication()->getLanguage()->_('MOD_FOOTER_LINE1');
        $lineOne = str_replace('%date%', HTMLHelper::_('date', 'now', 'Y'), $lineOne);
        $lineOne = str_replace('%sitename%', $this->getApplication()->get('sitename', ''), $lineOne);

        $data['lineone'] = $lineOne;

        return $data;
    }
}

The same content is in 191 releases, Joomla 4.4.0-alpha1 to 6.2.1-rc1. See them all, or every version of this file.