Moving position of price on product page with hooks? (2 posts)

  1. meadows.pete
    Posted 3 years ago #

    I'm trying to move the product price below the product short description, instead of above the product short description.

    I moved the title OK, but this one has me a little confused - the documentation doesn't really help too much either; it explains roughly what hooks/filters are and gives a long list of available hooks, but no real examples to guide you through to teach it unfortunately.

    Here's the code I used to move the title above the images/short-description

    /*---Move Product Title*/
    remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_title', 5 );
    add_action( 'woocommerce_before_single_product_summary', 'woocommerce_template_single_title', 5 );

    And I understand what it's doing - remove the product title from the product summary, and then place it back into the page before the product summary. Right?

    Anyway, what I want to do now is remove the price from the product summary, and then place it back into the product summary further down? Reordering within the summary is a little different to taking an element out and placing it above, so any help appreciated!



  2. Roy Ho
    Posted 3 years ago #

    If there are no hooks available, you can modify the template files. You will get a finer grain control as well.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WooCommerce
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic