WordPress.org

Ready to get started?Download WordPress

Forums

Woocommerce - Add action help (1 post)

  1. mattpitts74
    Member
    Posted 4 months ago #

    I'm trying to get a small line of extra text to show up on one particular product page. Using the add action I'm able to add the line to all products, but it only applies to one, so I have tried the if statement below, but its still just showing up on all the products.

    If anyone can help with this that would be amazing. Thanks

    add_action('woocommerce_single_product_summary','text_before_bucket');
    
                    function text_before_bucket() {
    
                  if ( is_product_category( 'PYO' ) ) {
                    echo 'choose you picking date below';
                  } 
    
                }

    Here's the page I working on http://www.bloom-dev.mac1to1.co.uk/product/bucket-mixed-flowers-and-foliage

Reply

You must log in to post.

About this Topic