Skip to content

Instantly share code, notes, and snippets.

@djrmom
Created January 29, 2021 22:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save djrmom/27c44f663d78d9fa8f061e4570d71d52 to your computer and use it in GitHub Desktop.
Save djrmom/27c44f663d78d9fa8f061e4570d71d52 to your computer and use it in GitHub Desktop.
facetwp product loop display code
<?php
if ( have_posts() ) {
do_action( 'woocommerce_before_shop_loop' );
woocommerce_product_loop_start();
while ( have_posts() ) {
the_post();
do_action( 'woocommerce_shop_loop' );
wc_get_template_part( 'content', 'product' );
}
woocommerce_product_loop_end();
do_action( 'woocommerce_after_shop_loop' );
} else {
do_action( 'woocommerce_no_products_found' );
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment