Display as Shortcode results.php cannot show Woo Product Price

Forums › Forums › Search & Filter Pro › Display as Shortcode results.php cannot show Woo Product Price

Viewing 3 posts – 1 through 3 (of 3 total)
  • Anonymous
    #191824

    Hi!

    I’m using the display as shortcode option, and have copied the results.php into /child-theme/search-filter/ folder.

    The temple override shows title, etc. But I cannot seem to show custom meta.

    I’m trying to display the product price.

    I have tried quite a few variations of methods – using globals with get_post_meta, get_the_ID, $product/$post->get_id(), etc. Pretty much every variant I could find/know already.

    My last guess is that the $query being referenced, has an issue.

    Please can you help?

    Trevor
    #191827

    Did you do something like this:

    <?php
      global $product;
      echo $product->get_price_html()
    ?>
    Anonymous
    #191950

    Hi Trevor,

    My apologies for wasting your time. Any of my code options would have worked, if I’d been looking at a category with products which had a price attached.

    Thank you!

Viewing 3 posts – 1 through 3 (of 3 total)
Search & Filter Support
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.

We also use cookies to store items in your cart as well as allowing your to login on the site.

You can adjust all of your cookie settings by navigating the tabs on the left hand side.

By continuing to use this site, you also agree to our Privacy Policy.