Please submit a private ticket if you need to share sensitive information, such as license details and admin credentials.

Okay
  Public Ticket #2898248
Pre-Sale Question
Closed

Comments

  • William started the conversation

    hi, i'm testing free version and works great for my goal except one aspect: is it possible to have individual button cart for each single product into group product? or is there an hook to get this by custom code?

    Regards

    Paolo

  • William replied

    hi, i forget to ask if it's possible to show only group product on woocommerce arvhive/shop page and hid all other product into the group.

    regards


  •  767
    Janilyn replied

    Hi William,

    Thank you for contacting WPClever Support Forum. 

    1. We’ve received your ticket and assigned one of our developers to help you answer that. 

    He’ll be looking into your question and responding with specific instructions as soon as possible. 

    Please stay patient as we're having very heavy workloads, it might take some time for our developers to reach back.

    2. Regarding your 2nd question, if you mean to hide all grouped items you added from the shop/archive page, then you can do 2 things:

    - Go to WPClever >> Grouped Product >> find Link to individual products then choose "No".

    - Go to each individual product page, adjust their Catalog Visibility to Hidden from Shop and Search archive.

    Then customers can only buy these grouped items from the Smart grouped product page while they cannot find or add them to the cart from the shop or archive page.

    Best regards.

    Janilyn T. - WPClever Support Agent

  •  1,226
    Dustin replied

    Hi William,

    Yes, you can do thatsmile.png

    Please add the below custom code (How to add custom code?)

    add_action( 'woosg_after_item', 'woosg_item_add_to_cart' );
    function woosg_item_add_to_cart( $woosg_product ) {
        echo '<div class="woosg-atc">';
        echo do_shortcode( '[add_to_cart show_price="false" id="' . $woosg_product->get_id() . '"]' );
        echo '</div>';
    }

    Then, also add below CSS code to WP-Admin → Appearance → Customize → Additional CSS:

    .woosg-atc {
        width: 160px;
        flex: 0 0 160px;
    }
    .woosg-atc .add_to_cart_inline {
        margin: 0 !important;
        padding: 0 !important;
        border: none !important;
    }
    .woosg-atc .add_to_cart_inline .button {
        display: block;
        text-align: center;
    }

    Best regards,
    Dustin