| Server IP : 54.36.91.62 / Your IP : 216.73.217.112 Web Server : Apache System : Linux webm013.cluster127.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64 User : coopiak ( 151928) PHP Version : 8.3.23 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/coopiak/amisdesseniors-fr/bordeaux/components/com_kunena/src/Layout/User/ |
Upload File : |
<?php
/**
* Kunena Component
*
* @package Kunena.Site
* @subpackage Layout.User
*
* @copyright Copyright (C) 2008 - 2025 Kunena Team. All rights reserved.
* @license https://www.gnu.org/copyleft/gpl.html GNU/GPL
* @link https://www.kunena.org
**/
namespace Kunena\Forum\Site\Layout\User;
\defined('_JEXEC') or die;
use Exception;
use Joomla\CMS\Factory;
use Joomla\CMS\Language\Text;
use Joomla\CMS\Plugin\PluginHelper;
use Kunena\Forum\Libraries\Config\KunenaConfig;
use Kunena\Forum\Libraries\Layout\KunenaLayout;
use Kunena\Forum\Libraries\User\KunenaUser;
use Kunena\Forum\Libraries\User\KunenaUserHelper;
use stdClass;
/**
* KunenaLayoutUserItem
*
* @since Kunena 5.1
*/
class UserEdit extends KunenaLayout
{
/**
* @var KunenaUser
* @since Kunena 6.0
*/
public $profile;
public $output;
public $user;
public $headerText;
public $pagination;
public $config;
public $ktemplate;
/**
* Method to get tabs for edit profile
*
* @return array
*
* @since Kunena 6.0
*
* @throws Exception
*/
public function getTabsEdit()
{
$myProfile = $this->profile->isMyself() || KunenaUserHelper::getMyself()->isAdmin() || KunenaUserHelper::getMyself()->isModerator();
// Define all tabs.
$tabs = [];
if ($myProfile) {
$tab = new stdClass();
$tab->title = Text::_('COM_KUNENA_PROFILE_EDIT_USER');
$tab->content = $this->subRequest('User/Edit/User');
$tab->active = true;
$tabs['User'] = $tab;
}
if ($myProfile) {
$tab = new stdClass();
$tab->title = Text::_('COM_KUNENA_PROFILE_EDIT_PROFILE');
$tab->content = $this->subRequest('User/Edit/Profile');
$tab->active = false;
$tabs['profile'] = $tab;
}
if ($myProfile) {
if (KunenaConfig::getInstance()->allowAvatarUpload || KunenaConfig::getInstance()->allowAvatarGallery) {
$tab = new stdClass();
$tab->title = Text::_('COM_KUNENA_PROFILE_EDIT_AVATAR');
$tab->content = $this->subRequest('User/Edit/Avatar');
$tab->active = false;
$tabs['avatar'] = $tab;
}
}
if ($myProfile) {
$tab = new stdClass();
$tab->title = Text::_('COM_KUNENA_PROFILE_EDIT_SETTINGS');
$tab->content = $this->subRequest('User/Edit/Settings');
$tab->active = false;
$tabs['settings'] = $tab;
}
PluginHelper::importPlugin('kunena');
$plugins = Factory::getApplication()->triggerEvent('on\Kunena\Forum\Libraries\User\KunenaUserTabsEdit', [$tabs]);
$tabs = $tabs + $plugins;
return $tabs;
}
}