• Closed by: Fred
  • Closed on: 05.05.21, 14:08
  • Reason: Closed
  • Comment: Glad to help!

Ticket #21311 - Customization of the product page

Hello, I have installed the theme with a child theme.
I need to customize the single product page.
For example, I have to put the stars (those of the reviews) under the product image, and not in the right column.
Which theme file should I edit, considering that I have a child theme and that the change must not be overwritten when we do the updates?
thank you for your support

Comments

Fred 16 Apr 2021, 10:55

Hi, Gabriele Breccia.
Here is the file of product page /themes/alysum/templates/catalog/product.tpl

Gabriele Breccia 16 Apr 2021, 12:09

To ensure that the changes are not overwritten when we make updates to the theme, does this file need to be copied to the child theme?
Thanks

Fred 16 Apr 2021, 13:10

just keep that file on your computer as a backup.
As for the child theme read more here https://devdocs.prestashop.com/1.7/themes/reference/template-inheritance/parent-child-feature/

Gabriele Breccia 19 Apr 2021, 17:16

If I set “product-page” as the product page template, do I always have to refer to the product.tpl file?

Attachments:

Schermata 2021-04-19 alle 17.... (54.8 KiB)
Fred 19 Apr 2021, 21:41

Product-page layout built with Page builder module. It’s files located in the /modules/pspagebuilder/views/templates/front/widgets

Gabriele Breccia 20 Apr 2021, 09:43

In your first post, you wrote that I can edit the “product.tpl” file, this works if the “product page layou” is set as default. If, on the other hand, I set product-page as “product page layou”, the changes made to the “product.tpl” file are no longer visible.
I would like to understand which file I need to edit to see the changes.
thank you

Fred 20 Apr 2021, 14:51

As I can see you have selected product page layout composed in the Page builder. In this case product page widget files located in the folder /modules/pspagebuilder/views/templates/front/widgets
The list of widgets is

widget_productpageaccessories.tpl
widget_productpagebuy.tpl
widget_productpagedescription.tpl
widget_productpagefooter.tpl
widget_productpageimage.tpl
widget_productpageinfo.tpl
widget_productpagelongdescription.tpl
widget_productpageprice.tpl
widget_productpagetabs.tpl
widget_productpagetitle.tpl
Gabriele Breccia 20 Apr 2021, 15:29

Ok, thanks

Fred 20 Apr 2021, 16:04

you are welcome

Gabriele Breccia 05 May 2021, 14:03

Thanks for your support, you can close the ticket!