I have a custom loop on my website home page of best selling products.

I am using wc_get_template_part('content', 'product'); to pull in the products.

But when I click the buy button, the buy button does not get the tick added to it, so it doesn't look the purchase has worked for users. The item is added to the cart. The buttons work as they should on other pages.

I have checked that "Enable AJAX add to basket buttons on archives" is ticked.

I have tried adding global to my code to see if that makes a difference.

There are no JS errors being logged.

Any ideas why it's not working as expected?

Here is my code:

    global $woocommerce_loop;
    global $product;
    $args = array(
    'post_type' => 'product',
    'meta_key' => 'total_sales',
    'orderby' => 'meta_value_num',
    'posts_per_page' => 12
    $product = new WP_Query( $args );

    if ($product->have_posts()) {
    while ($product->have_posts()) {
        wc_get_template_part('content', 'product');

1 Answer 1


The answer was that I had dequeued the woocommerce style sheets and fonts, adding the CSS back in made the tick marks appear

.added:after {
    font-family: WooCommerce;
    content: '\e017';
    margin-left: .53em;
    vertical-align: bottom;
    display: inline-block;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.