Monthly Archives: May 2019
The "Product Key is empty or invalid. The extension has been automatically disabled." issue appears because of three common reasons. Usually, it's because you use the outdated version of the Magefan_Communty module, you downloaded a free version of the module for Magento Commerce or you use Translation extension v2.2.9.
Let's see what you can do to fix this issue in different cases.
Solution for Magento Open Source (CE)
If you get this error while saving the Magefan extension on the Magento Community edition and don't see any Product Key field, as on the screenshot:
make sure that you have the latest version of the Magefan Community extension.
Note: Magefan Community is not a Magefan Blog or Magefan Login as Customer. It is a separate module that is used together with all Magefan extensions.
To check the version of the Magefan Community extension have a look inside one of these files:
app/code/Magefan/Community/composer.json
app/code/Magefan/Community/etc/module.xml
vendor/magefan/module-community/composer.json
Sometimes instead of the real customer IP address, you can see 127.0.0.1 or some other wrong customer IP in your Magento 2 Admin panel. It can be due to proxies, like Varnish, Cloudflare, Sucuri.net, that may be enabled for your Magento 2 store.
To solve the wrong IP address issue you need to:
1. Create a new file in M2 directory:
app/etc/XIP/di.xml
2. Paste the code:
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
<type name="Magento\Framework\HTTP\PhpEnvironment\RemoteAddress">
<arguments>
<argument name="alternativeHeaders" xsi:type="array">
<item name="x-client-ip" xsi:type="string">HTTP_X_REAL_IP</item>
<item name="x-cf-connecting-ip" xsi:type="string">HTTP_CF_CONNECTING_IP</item>
<!-- <item name="x-cf-mfcustom-ip" xsi:type="string">SOME_CUSTOM_SERVER_KEY</item> -->
</argument>
</arguments>
</type>
</config>
3. Save the file,
Configuring Image Lazy Load is one of the great tips for Magento 2 image optimization that allows you to improve your website loading speed and reduce the page size by loading images gradually.
Once your images are lazy-loaded you are sure there won't be any delay in loading the page caused by images so that your customers receive the best user experience.
How to Configure Image Lazy Load in Magento 2?
First, you need to install the Magento 2 Image Lazy Load Extension by Magefan. Then, navigate to Stores > Configuration > Magefan Extensions > Image Lazy Load and enable the extension. There are two options you can choose from. Let's talk more about both.
Lazy Load All Website Images
All you need to do to lazy load all website images is choose a corresponding option in the Blocks to Lazy Load select box. However, if you want to exclude some images from the lazy load, define them in the Lazy Load Blocks section and specify how many First Images from those blocks To Skip.