[Resolved] Product count & pagination using Facetwp

Home Forums Support Product count & pagination using Facetwp

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #1286989
    Juan Manuel


    I am struggling to make facetwp to work properly in my product category pages. Filters seem to work properly, but since facetwp works in ajax, pagination and product count (ie showing X from Y products) get broken, as they don’t get updated.

    In facetwp documentation, I found this and also this for those cases where you are using archive pages (my case), where they point out that the “facetwp-template” class could be added to the listing to fix this.

    And that’s where I am stuck. I don’t see any place to add this in GeneratePress, and it feels wrong to try to add that in Woocommerce plugin.

    Any idea on how to fix it?

    Edit: I also found these 2, they look great, but old, idk if they are trustworthy.


    Also, thanks a lot for your wonderful support (found a lot of answers in this forum) and theme, and congrats for the 6 years 🙂

    Customer Support

    Hi there,

    The solutions you’ve found looks ok to me.

    Maybe give them a shot and see if that works for you?

    If not you might need to check with the plugin support to see if they can provide explanations in better details.

    Juan Manuel

    Hi Leo,

    Thanks for your answer.

    Just in case someone needs it in the future, this fixed it:

    // Removes default WooCommerce pagination.
    remove_action( 'woocommerce_after_shop_loop', 'woocommerce_pagination' );
    add_action( 'woocommerce_after_shop_loop', 'custom_woocommerce_pagination' );
    //Adds FacetWP's pagination on WooCommerce archives.
    function custom_woocommerce_pagination() {
        echo facetwp_display( 'pager' );

    That fixes the pagination, the rest (product sorting and count) can be fixed the same way by just using different actions and pushing the appropriate facet.

    Best regards,

    Customer Support

    Glad to hear and thanks for sharing 🙂

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.