Jump to content

how to show product attributes on product listing page in prestashop 1.7


PrS

Recommended Posts

Hello,
I am looking for a way to display a products attributes on the product listing page.
for eg. show all available sizes of my product on product listing page and user can select any size from product listing too.

Thanks for any kind of help

Link to comment
Share on other sites

  • 10 months later...
  • 8 months later...

Actually you can do it without a module - Prestashop already displays colors on product listing, so all we need to do is to change this into sizes.

You need to know ID of your sizes attribute group, having that (example for the classic theme):

1. put the attached Product.php file into override/classes

2. in that file, replace ATTR_GROUP_ID in line 22 with ID of your attribute group responsible for sizes (for example 1)

3. modify \themes\classic\templates\catalog\_partials\variant-links.tpl to show variant name (also see attached file)

4. clear the cache and you should be done :)

 

Product.php variant-links.tpl

Edited by Daresh (see edit history)
  • Like 4
  • Thanks 1
Link to comment
Share on other sites

  • 1 year later...
  • 2 years later...

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...