• Resolved Imagercmb

    (@rcmb)


    After I upgraded Visualizer to v 3.9.4 my site crashed with “An error of type E_PARSE was caused in line 45 of the file /home/<site>/public_html/wp-content/plugins/visualizer/vendor/composer/autoload_real.php. Error message: syntax error, unexpected ‘(‘.

    I have had to deactivate the plugin which is a shame as I have found it really useful and been very pleased with it for the last year or so. I have tried uninstalling the plug in and then reinstalling but get “Plugin could not be activated because it triggered a fatal error.” and the same error.

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Support ImagePoonam Namdev

    (@poonam9)

    Hi @rcmb,

    Sorry to hear about the difficulties encountered.

    Please confirm the PHP version you are using so we can take a closer look at this issue. Our plugin requires at least PHP v7.4 to work properly.

    I recommend you please attempt to disable all plugins. If the problem goes away, enable them one by one to identify the source of your troubles.

    Let me know how it goes.

    Thread Starter Imagercmb

    (@rcmb)

    My sites is on PHP (5.6.40).

    WordPress version 6.1.1 Active theme: Hestia (version 3.0.16) Current plugin: Visualizer: Tables and Charts for WordPress (version 3.9.4) PHP version 5.6.40

    However, I cannot upgrade as I get:

    WordPress recommends everyone update their PHP versions, but this is often not possible.This is why your site is using HardenedPHP, by CloudLinux.HardenedPHP is a way of supporting older versions of PHP without compromising security.If you’ve been brought here by WordPress’s PHP update warnings, there is nothing you need to do.

    I don’t think the problem is to do with the version of PHP or other plugins. I think there is an error in file autoload_real.php

    I will try and attach the file.

    Thread Starter Imagercmb

    (@rcmb)

    <?php
    
    // autoload_real.php @generated by Composer
    
    class ComposerAutoloaderInit13a4206e48217fda3df03a3590a64aae
    {
        private static $loader;
    
        public static function loadClassLoader($class)
        {
            if ('Composer\Autoload\ClassLoader' === $class) {
                require __DIR__ . '/ClassLoader.php';
            }
        }
    
        /**
         * @return \Composer\Autoload\ClassLoader
         */
        public static function getLoader()
        {
            if (null !== self::$loader) {
                return self::$loader;
            }
    
            require __DIR__ . '/platform_check.php';
    
            spl_autoload_register(array('ComposerAutoloaderInit13a4206e48217fda3df03a3590a64aae', 'loadClassLoader'), true, true);
            self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
            spl_autoload_unregister(array('ComposerAutoloaderInit13a4206e48217fda3df03a3590a64aae', 'loadClassLoader'));
    
            require __DIR__ . '/autoload_static.php';
            call_user_func(\Composer\Autoload\ComposerStaticInit13a4206e48217fda3df03a3590a64aae::getInitializer($loader));
    
            $loader->register(true);
    
            $filesToLoad = \Composer\Autoload\ComposerStaticInit13a4206e48217fda3df03a3590a64aae::$files;
            $requireFile = static function ($fileIdentifier, $file) {
                if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
                    $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
    
                    require $file;
                }
            };
            foreach ($filesToLoad as $fileIdentifier => $file) {
                ($requireFile)($fileIdentifier, $file);
            }
    
            return $loader;
        }
    }
    
    Thread Starter Imagercmb

    (@rcmb)

    It is objecting to “unexpected ‘(‘ “.

    Plugin Support ImagePoonam Namdev

    (@poonam9)

    Hi @rcmb,

    This is the issue with the older version of PHP because we are not able to replicate the same issue with the latest version of PHP. You can check the same by creating a test instance here.

    Please contact your host CloudLinux if they can help in resolving the issue.

    Unfortunately, we can’t do anything if you don’t want to upgrade the PHP version.

    Hope you will understand.

    Thread Starter Imagercmb

    (@rcmb)

    Hi Poonam

    Thank you for your suggestions. I do appreciate the need to keep up to date with software but unfortunately my hands are tied with regard to upgrading PHP. I will contact my hosting company as you suggest.

    Thread Starter Imagercmb

    (@rcmb)

    I have discovered that I can easily change my PHP version in cPanel. I set it to v7.4 as you suggested and it’s done the trick!! So far no problems with other plug-ins noticed.

    Many thanks for your help.

    Plugin Support ImagePoonam Namdev

    (@poonam9)

    Hi @rcmb,

    I am glad to hear you got it working.

    Have a great day!

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘EPARSE Error in autoload_real.php after upgrading to 3.9.4’ is closed to new replies.