WordPress.org

Support

Support » Plugins and Hacks » WooCommerce » Shop/Catalog Page: Need Product Name and Add to Cart

Shop/Catalog Page: Need Product Name and Add to Cart

Viewing 7 replies - 1 through 7 (of 7 total)
  • without having access to that exact theme, it’s difficult to know exactly what will work well, but I would go with

    add_action( ‘woocommerce_after_shop_loop_item’, ‘woocommerce_template_loop_add_to_cart’, 10 );

    Thank you so much for your response. It’s the Argentum theme from Woothemes. Where would I add that line of code?

    Yeah, I could tell what theme it was, but my point was that I don’t have access to see the code to know whether that will work well.

    That line of code would go in your functions.php on your theme, and only adds the “add to cart” button.

    I really appreciate it – I will try to do a dummy install on another site and see if it works. Thanks again!

    I guess I still need to figure out how to put the product name. This is the look I’m going for: http://www.winksoap.com/

    to add the title and then the add to cart

    function add_wc_title(){
    return ‘<h3>’ . get_the_title() . ‘</h3>’;
    }
    add_action( ‘woocommerce_after_shop_loop_item’, ‘add_wc_title’, 10 );
    add_action( ‘woocommerce_after_shop_loop_item’, ‘woocommerce_template_loop_add_to_cart’, 10 );

    This worked great for getting the “add to cart” to show up. The title didn’t show up, but I am determined to get to the bottom of this – I will tinker with it.

    I really appreciate it!

    maybe cos it’s already firing inside the image. You might need to remove the hook and readd it like this:

    remove_action( ‘woocommerce_after_shop_loop_item’, ‘add_wc_title’);
    add_action( ‘woocommerce_after_shop_loop_item’, ‘add_wc_title’, 10 );

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Shop/Catalog Page: Need Product Name and Add to Cart’ is closed to new replies.
Skip to toolbar