ValterV Posted February 4, 2020 Share Posted February 4, 2020 (edited) Hello, I want to hide that squares attribute colors in category page. Dont looks nice. Any one know here? Edited February 6, 2020 by ValterV (see edit history) Link to comment Share on other sites More sharing options...
Guest Posted February 4, 2020 Share Posted February 4, 2020 Prestashop version ? Link to comment Share on other sites More sharing options...
ValterV Posted February 4, 2020 Author Share Posted February 4, 2020 1.6.1.24 Link to comment Share on other sites More sharing options...
Guest Posted February 4, 2020 Share Posted February 4, 2020 (edited) Ok, go to: prestashop/themes/default-bootstrap/product-list-colors.tpl change <ul class="color_to_pick_list clearfix"> to <ul class="color_to_pick_list clearfix" style="display: none !important;"> or comment: <!-- <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')} <li> <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" /> {/if} </a> </li> {/if} {/foreach} </ul> --> After change code, clear Prestashop and browser cache. product-list-colors.tpl Edited February 4, 2020 by Guest (see edit history) Link to comment Share on other sites More sharing options...
ValterV Posted February 5, 2020 Author Share Posted February 5, 2020 Thaks for your help. The code result, but not for all products. I think when i have small number or imgs of attributes combinations , the boxes appears. I dont find why... Link to comment Share on other sites More sharing options...
Guest Posted February 5, 2020 Share Posted February 5, 2020 (edited) themes/default-bootstrap/product-list.tpl find line 170 ...172: {if isset($product.color_list)} <div class="color-list-container">{$product.color_list}</div> {/if} and replace to: {if isset($product.color_list)} <div class="color-list-container" style="display: none !important;">{$product.color_list}</div> {/if} If it helps you, your LIKE will help me 😉 Edited February 5, 2020 by Guest (see edit history) Link to comment Share on other sites More sharing options...
ValterV Posted February 5, 2020 Author Share Posted February 5, 2020 YEEESS , its fixed. Thaks a lot Guest Link to comment Share on other sites More sharing options...
Guest Posted February 5, 2020 Share Posted February 5, 2020 I gladly helped. Please mark the topic as SOLVED. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now