Site logo

Archived topic

Remove "Hover Effect" & "Add to Cart" Button on Catalog Page

5 replies · Started by Solo on September 30, 2018

Viewing posts 1–6 of 6

Hi,

I've bought the Premium theme. And having trouble customizing my site.

https://meck.vn

How do I remove the "Add to Cart" button on the Home page?

How do I remove the "hover effect" on product image the Home page?

Please help. I've looked everywhere for a solution.

Hi there,

I need some clarification on this.

- Do you want to remove the Add to Cart button on Home page only or all pages?
If all pages, how are people going to purchase your product?

- Same as above, do you want to remove the show second image hover effect on home page only or all pages?

Let me know :)

Hi Leo,

I only want to remove the Hover Effect & Add To Cart button on the Homepage.

Solo

- Try this PHP snippet to remove second image hover effect on home page:

add_filter( 'option_generate_woocommerce_settings','lh_remove_second_image_hover' );
function lh_remove_second_image_hover( $options ) {
    if ( is_front_page() ) {
        $options['product_secondary_image'] = 'false';
    }
    
    return $options;
}

More info here: https://docs.generatepress.com/article/option_generate_woocommerce_settings/

- This CSS should remove the add to cart button on home page:

.woocommerce.home ul.products li.product .button {
    display: none;
}

Leo,

Thank you so much for your help!

The PHP Snippet didn't work for me. The CSS worked.

But I found that both of these two settings can be changed at:

Customizing ▸ Layout ▸ WooCommerce

I appreciate your following through.

Solo

No problem :)

This archived topic is closed to new replies.