Jump to content

Lost "Product Color Attribute" Only in Category View

Recommended Posts


An interesting issue the regenerate thumbnails system have been unable to fix. I have 100 products that show all information correct on their product pages however when viewing 1 product in their category view they don't show the color boxes underneath but cleared out squares for the colors. It doesn't affect purchasing or anything but i'd like to get back the product attribute color squares that correctly displayed when loaded in. (I have used google inspect on the clear squares however it doesn't lead to an image file to find and replace for a clear box back to the color black for instance.)

Any further ideas to try?


Share this post

Link to post
Share on other sites

Here is an image of the issue. As you can see the color attribute boxes on the category view are without color and all clear. Once the product is chosen and on the product page they appear.

Any ideas?


Share this post

Link to post
Share on other sites

On further analysis, all the product attributes in which I use a photo to show an attribute does not show in the category view on any product. If using the HEX color picker, those show without issue on any part of the site.

Anyone have this issue recently. Prestashop Build

Share this post

Link to post
Share on other sites

Further research using Google inspect:


The <li> list code for the product on the category view uses a HEX color code string but it's wrong and remains clear as an image was placed for that attribute color, not a HEX code.

The product page shows a correct image file for the product attribute with the appropriate <li> code thus not calling wrong code of a HEX color option.

Share this post

Link to post
Share on other sites

SOLVED. I had a theme file with no code in it. An older post on the subject was assisted by @vekiaand he recommended the below:


Check please contents of /themes/your-theme/product-list-colors.tpl file


* 2007-2014 PrestaShop
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*  @author PrestaShop SA <contact@prestashop.com>
*  @copyright  2007-2014 PrestaShop SA
*  @license   http://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
*  International Registered Trademark & Property of PrestaShop SA
{if isset($colors_list)}
<ul class="color_to_pick_list clearfix">
    {foreach from=$colors_list item='color'}
        {if isset($col_img_dir)}
            {assign var='img_color_exists' value=file_exists($col_img_dir|cat:$color.id_attribute|cat:'.jpg')}
                <a href="{$link->getProductLink($color.id_product, null, null, null, null, null, $color.id_product_attribute, Configuration::get('PS_REWRITING_SETTINGS'), false, true)|escape:'html':'UTF-8'}" id="color_{$color.id_product_attribute|intval}" class="color_pick"{if !$img_color_exists && isset($color.color) && $color.color} style="background:{$color.color};"{/if}>
                    {if $img_color_exists}
                        <img src="{$img_col_dir}{$color.id_attribute|intval}.jpg" alt="{$color.name|escape:'html':'UTF-8'}" title="{$color.name|escape:'html':'UTF-8'}" width="20" height="20" />




I found the file in my theme folder and added it in. Solved the issue!

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More