Combination images as textures PrestaShop 1.7 module
Take the first image of every combination as textures, this module can save you a lot of time of uploading texture images one by one.
Installation
1. Use the "Upload a module" button on "BO > Modules" page to install the module.
2. Modify the \themes\your-theme-name\templates\catalog\_partials\product-variants.tpl file to add this code
1 |
Right above this one
1 | {if $group_attribute.html_color_code && !$group_attribute.texture} |
You may need to clear the Smarty cache to make the modification work.
For transformer theme and Panda theme users, if you are using versions later than transformer theme v4.3.8 or Panda theme v2.4.8, then no need to add the code, because it has already been added by default.
Features
- Take the first image of every combination as textures.
- Works for attributes which are in "Color or texture" type.
- This module provides 4 different ways to choose products which you want this module applying to, they are "All products", "By categories", "By brands", "Choose some products".
- Ability to choose image type.
- Custom css code.
- No override files.
Compatibility
- Prestashop1.7.
- Transformer theme, Panda theme, Classic theme and most all other themes.
How to upgrade.
How to upgrade?
Use the "Upload a module" button on "BO > Modules" page to upload the new version to your site, it's the same as how to install, don't worry all your data will be safe, prestashop will just upload updated files to your site, it won't reinstall this module.
How to get support.
If you have any questions with the module, post them out on the prestashop module support forum, we'll help you out.
Changelog.
- v1.1 (September 4, 2020) Fixed a compatibity issue with 1.7.6.x, which stopped the product selector on the back office from working..
- v1.0 (October 8, 2019) Initial release.
I will keep upgrading this module, let me messages if you have feature requests.
Will this module be updated to work with PS8? Ive just tried installing it and receive the following error
" Oops... looks like an unexpected error occurred.
key_exists(): Argument #2 ($array) must be of type array, StProThumbGroupClass given
[TypeError 0]"
Thanks for your great work
Hi,
If you have any problems, please contact us via the "Contact" page.
Best regards.
Messaged via email.. But just realised it works on PHP7, but not PHP8
The ecolife theme is used. The shopping cart does not display the attribute image, but only the default product image
Can you help me
I did not find those lines where you need to register the code
Please contact the developer of the theme to help you identify it. maybe the theme changed those lines.