Select Page

Rating Stars in Product Loop (Archive)

Home Forums Support Rating Stars in Product Loop (Archive)

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • Helpful
    Up
    0
    Down
    Not Helpful

    Howdy!

    I am looking to amend the product loop on archive pages and modules so that the star ratings for the products appear below the ‘Learn More’ button (would also be the add to cart button I had that set up).

    I have this snippet set up:
    remove_action( ‘woocommerce_after_shop_loop_item_title’, ‘woocommerce_template_loop_rating’, 5 );
    add_action(‘woocommerce_after_shop_loop_item’, ‘woocommerce_template_loop_rating’ );

    However, because of how the Learn More button is called in the loop, the rating is only able to display above the Learn More button. It seems that the action for the button is being called after the rating loop?

    Is there a way to know what the add_action function is for the learn more/add to cart button so that I can remove it and then add it before the product rating loop?

    Did that makes sense?

    Thank you!

    Helpful
    Up
    0
    Down
    Not Helpful

    Depends where you are using it and how you are.

    I would say the easiest way would be to hide or remove it from there and use the ratings module to position it where you want

    Helpful
    Up
    0
    Down
    Not Helpful

    I don’t know if I explained that properly…

    I am looking at the product loop on archive pages, not the product page itself. That would be, and is, easy to adapt.

    Here is the image of what is happening : http://magaimg.net/img/7tes.png
    Normally the star ratings appear above the price and under the title, and after using the snippet above (which is supposed to place the loop at the end of everything) it is being superseded by the Learn More button as the ending of the loop.

    Here is what we are looking to do with the ratings: http://magaimg.net/img/7tev.png
    with the rating below the button.

    These are displayed in places like the home page or the related products.

    Is something like that possible within BC?

    Helpful
    Up
    0
    Down
    Not Helpful

    Have you tried to make a custom loop layout? With this you can choose the modules and positions of where they are.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.