re: https://modestmix.com/shop/benefit-teas/go-the-fuck-to-sleep/

I'd like to move the price "$4.99–$24.99" below the product short description "Seriously. Drink a cup of this..."

enter image description here

Any ideas how to do this? I already have a child theme, but I'm not sure what WooCommerce file needs to be overridden.

closed as off-topic by Nicolai, Milo, TheDeadMedic, Mark Kaplun, gmazzap Oct 29 '15 at 9:25

This question appears to be off-topic. The users who voted to close gave this specific reason:

If this question can be reworded to fit the rules in the help center, please edit the question.


If you look at woocommerce/templates/content-single-product.php you'll see that the product summary is constructed using hooks with different priorities.

Here's the relevant section:

         * woocommerce_single_product_summary hook
         * @hooked woocommerce_template_single_title - 5
         * @hooked woocommerce_template_single_rating - 10
         * @hooked woocommerce_template_single_price - 10
         * @hooked woocommerce_template_single_excerpt - 20
         * @hooked woocommerce_template_single_add_to_cart - 30
         * @hooked woocommerce_template_single_meta - 40
         * @hooked woocommerce_template_single_sharing - 50
        do_action( 'woocommerce_single_product_summary' );

The price has a priority of 10, the excerpt has a priority of 20. To swap them around, change the priorities by modifying the actions in your child theme's functions.php.

Like this:

remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_price', 10 );

remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_excerpt', 20 );

add_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_excerpt', 10 );

add_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_price', 20 );
  • 5
    You ROCK! Thanks for the awesome explanation and solution :) – Kane Oct 27 '15 at 22:44

Not the answer you're looking for? Browse other questions tagged or ask your own question.