Menu Close
    Searching for an experienced Prestashop Development Company ?

    Prestashop Redis Cache

    Prestashop Redis Cache helps in improving the loading time of your store. It creates an in-memory cache to store high-level data types.

    Check the overview of the plugin in the video mentioned-below –

    Features

    • Improves the loading time of the web pages by using a structured way to store data in memory.
    • A faster loading website leads to improved customer experience.
    • Reduces the bounce rate on the website.
    • Stores cache in Redis.
    • Stores page cache in Redis.
    • Improve the overall performance of your Prestashop store.

    Installation

    • Firstly, go to the Module Manager in Back office and click on ‘upload a module’.
    • After that, Drag and drop the module file or select the file from the system.
    • In this way, the module installation will be successful.
    Click to upload a module
    Drop or upload the file from the system
    Prestashop Redis Cache module is installed

    NOTE:

    In Prestashop, from version 1.7.3.0 to 1.7.6.x, to display CachePhpRedis radio option on the performance->caching section. Please add the following code in CachingType.php file.

    Path: prestashop/src/PrestaShopBundle/Form/Admin/AdvancedParameters/Performance/CachingType.php

    (1) Add this code:-

    use PrestaShop\PrestaShop\Core\Addon\Module\ModuleManagerBuilder;

    At line 34, just after use Symfony\Component\OptionsResolver\OptionsResolver;

    (2) Add this code:-

    public function isWkRedisModuleEnabled()
    {
    $moduleManagerBuilder = ModuleManagerBuilder::getInstance();
    $moduleManager = $moduleManagerBuilder->build();
    if ($moduleManager->isInstalled('wkrediscache') && $moduleManager->isEnabled('wkrediscache')) {
    return true;
    }
    
    return false;
    }

    At line 46, Just after

    private $extensionsList = [
    'CacheMemcache' => ['memcache'],
    'CacheMemcached' => ['memcached'],
    'CacheApc' => ['apc', 'apcu'],
    'CacheXcache' => ['xcache'],
    ];

    (3) Add this code:-

    $choices = array(
    'Memcached via PHP::Memcache' => 'CacheMemcache',
    'Memcached via PHP::Memcached' => 'CacheMemcached',
    'APC' => 'CacheApc',
    'Xcache' => 'CacheXcache',
    );
    if ($this->isWkRedisModuleEnabled()) {
    $choices['CachePhpRedis'] = 'CachePhpRedis';
    $this->extensionsList['CachePhpRedis'] = array('CachePhpRedis');
    }

    At line 61, just after public function buildForm(FormBuilderInterface $builder, array $options) {

    (4) Remove this below code from line 74 to 79 just after ->add(‘caching_system’, ChoiceType::class, [

    'choices' => [
    'Memcached via PHP::Memcache' => 'CacheMemcache',
    'Memcached via PHP::Memcached' => 'CacheMemcached',
    'APC' => 'CacheApc',
    'Xcache' => 'CacheXcache',
    ],

    And add this below code at line 74

    'choices' => $choices,

    (5) Add this code:-

    if ($this->isWkRedisModuleEnabled()) {
    if ($extensionName == 'CachePhpRedis') {
    $disabled = false;
    break;
    }
    }

    At line 91, just after foreach ($this->extensionsList[$index] as $extensionName) {

    (6) Add this code

    'CachePhpRedis' => $this->trans('CachePhpRedis', 'Admin.Advparameters.Feature')

    At line 179, just after

    'CacheXcache' => $this->trans('Xcache', 'Admin.Advparameters.Feature')
    . ' '
    . $this->trans(
    '(you must install the [a]Xcache extension[/a])',
    'Admin.Advparameters.Notification',
    [
    '[a]' => '<a href="http://xcache.lighttpd.net" target="_blank">',
    '[/a]' => '</a>',
    ]
    ),

    Module Configuration

    After the successful installation of the module, follow the below steps.

    • Firstly go to the Advanced Parameters section.
    • Then go to the caching section in the performance tab.
    • At last, you need to enable caching.
    Performance-•-Demo

    Firstly, you enable cache and select Redis as caching system. After that, you can configure the module.

    In the configuration settings, you need enter following details

    • Redis server IP
    • Port of Redis server
    • Authentication key(if applicable)
    • and the Database number
    Prestashop Redis Cache configuration

    In case, if admin doesn’t enable caching, then admin can not configure the module. As a result, the shop will not be connected with Redis.

    Prestashop Redis Cache configuration

    So, This was all about Prestashop Redis Cache Module. Moreover, this document will help you in checking the functionality of the module in a better way. Also, do let us know about your views in the comments.

    Support

    For any kind of technical assistance or query, please raise a ticket or send us a mail at [email protected]

    Also, please explore our Prestashop development services and vast range of quality Prestashop addons.

    Current Product Version - 4.0.1

    Supported Framework Version - 1.7.x.x

    Blog Version - 1.7.x.x
    • Version 1.7.x.x
    • Version 1.6.x.x
    . . .
    Discuss on Helpdesk

    Leave a Comment

    Your email address will not be published. Required fields are marked*


    4 comments

  • Kuba
    Hi,
    Is it possible to test this module on my site before buying it?

    Best wishes,
    Kuba

    • Anuj Verma (Moderator)
      Hello

      Thanks for showing interest in our products

      Well, all of our modules have open source code that is code for every module is readily available once you get the module. Since our code is not encrypted, so we do not provide any trial version for our module.

      However, you can check the module live demo through the link given on the product page.

      In case of any query/doubt, please raise a ticket at our support ticket system https://webkul.com/ticket/ or you can mail us at [email protected].

      Best Regards
      Anuj Verma

  • spott
    Live demo doesn’t work!
    From module configuration: Caching is Not Enabled, Please Enabled Cache from Performance tab.
    Cache System should be set as Redis from Performance tab.
    But Perfomance tab is disabled for this user….
    • Anuj Verma (Moderator)
      Hello

      Thanks for showing interest in our products

      Well, the Advance Parameter tab is restricted in the Demo, due to security purposes. But, now we have provided the access specifically for the ‘Performance’ tab, so the user will be able to configure the ‘Cache’ setting. Therefore, please check again.

      In case of any query/doubt, please raise a ticket at our support ticket system https://webkul.com/ticket/ or you can mail us at [email protected].

      Best Regards
      Anuj Verma

  • Back to Top

    Table of Content

    Hide Index