• Resolved jamiebh

    (@jamiebh)


    Hi,
    I’m trying to add some information to all my product pages underneath the price and above the add to cart button in woocommerce. I have managed to do this by editing the price.php file in “wp-content > plugins > woocommerce > templates > single product”
    This seems to work but when woocommerce updates it overwrites the file. Is there a better way to do this via plugin or some css using a custom code plug in?
    Thanks in advance and relatively new to this so apologies if I’m in the wrong place or I haven’t made any sense!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Stef

    (@serafinnyc)

    You need to make sure you are working in a child theme and then copy that template file over to your Child theme.

    If you don’t have a child theme here’s a great tutorial on how to create one.
    https://docs.woocommerce.com/document/set-up-and-use-a-child-theme/

    How to override a template?

    To override the shop page,
    copy: wp-content/plugins/woocommerce/templates/archive-product.php
    to wp-content/themes/your_theme_name/woocommerce/archive-product.php

    and then make the necessary changes to the template in your themes folder.

    Thread Starter jamiebh

    (@jamiebh)

    Thanks! Think that has done what i needed it to!

    Stef

    (@serafinnyc)

    Welcome

    Plugin Support abwaita a11n

    (@abwaita)

    Hi @jamiebh,

    Glad to hear that you were able to find a suitable solution!

    I’ll mark this thread as resolved now. If you have any further questions, I recommend creating a new thread.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Info to all product pages’ is closed to new replies.