Plugin to display posts, pages, any custom post type, or taxonomy terms via shortcode. Choose from horizontal, grid, overlay, or custom layout templates.
bs Loop uses the theme’s loop templates in /template-parts/loop/, making every card design overridable from a child theme. It is the base plugin for bs Swiper and bs Isotope, which extend it with slider and filter functionality respectively. The shortcode supports any post type, taxonomy, or term, making it equally useful for blog archives, WooCommerce product grids, portfolio pages, or organizing child pages under a parent.
terms-slug, multiple terms separated by comma, requires the tax="" attribute terms="cars" terms="cars, boats"
N/A
exclude_terms=""
Exclude posts from specific taxonomy terms (slugs, comma-separated) exclude_terms="cars" exclude_terms="cars, boats"
N/A
terms_parent=""
Id of a hierarchical parent term, multiple terms separated by comma, requires the tax="" attribute. terms_parent="789" terms_parent="789, 101112"
Vehicles (id=”789″) – Cars – Boats
Animals (id=”101112″) – Cats – Dogs
N/A
post_parent=""
ID of a hierarchical post type (page) to show child elements, multiple terms separated by comma post_parent="123" post_parent="123, 456"
N/A
featured=""
true – pulls featured products
false
out_of_stock=""
true – shows out of stock products
false
on_sale=""
true – shows only on sale products
false
show_hidden=""
true – shows products hidden from catalog
false
related_to=""
Shows posts that share the same taxonomy terms (requires tax="" – e.g., tax="category" or tax="post_tag"). Automatically excludes the current post when used within a single post/page.
Usage examples: related_to="current" – Use current post as reference (works in single post templates only) related_to="123" – Use specific post ID as reference related_to="current" tax="category" – Show posts from same categories related_to="current" tax="post_tag" – Show posts from same tags related_to="current" tax="product_cat" type="product" – Show related products
Note: When related_to is empty, the shortcode functions as a normal query without excluding any posts.
N/A
Select Taxonomy (Show Terms instead of Posts)
[bsfa fa-solid fa-circle-xmark] bs Isotope
If type="" matches a registered taxonomy (e.g. product_cat, category, post_tag) instead of a post type, bs-loop renders a grid of taxonomy terms instead of posts — useful for category overview pages.
[bs-loop layout="grid" type="product_cat"]
Attribute
Description
Default
type=""
Taxonomy name instead of a post type type="product_cat" type="category" type="post_tag" type="my_custom_taxonomy"
N/A
id=""
Single term id, multiple term id’s separated by comma id="123" id="123, 456"
N/A
terms_parent=""
Show only child terms of given parent term id(s), multiple separated by comma terms_parent="789" terms_parent="789, 101112"
N/A
posts=""
Limit number of terms shown posts="6"
-1
order=""
ASC or DESC
ASC
orderby=""
Any get_terms() orderby value name, slug, count, term_id, etc.
name
tax="", terms="", post_parent="", featured="", on_sale="", out_of_stock="", and show_hidden="" only apply when type="" is a post type — this mode shows terms, not posts, so those attributes are ignored. id="" and terms_parent="" are alternative ways to select terms; use one or the other, not both.
Template selection mirrors how type="product" works for posts:
type="product_cat" or type="product_tag" always render via template-parts/loop/cards-wc-product-cat.php, regardless of layout="".
Any other taxonomy (category, post_tag, custom taxonomies) follows layout="" the same way posts do: grid → cards-grid.php, overlay → cards-overlay.php, default/horizontal → cards-horizontal.php, custom → custom.php.
Term cards use the term’s thumbnail_id meta for an image (the same meta key WooCommerce uses for product category images). Core WordPress doesn’t provide an admin UI to set this for category/post_tag— without a plugin or custom field to populate it, those term cards render without an image. For cards-horizontal.php/cards-grid.php that’s harmless (the card body still gives it normal height). Avoid layout="overlay" for taxonomies without a term thumbnail — that layout’s height comes entirely from the image, so a missing thumbnail can collapse the card to zero height.
Ordering & Limit
Control the sort direction, sort field, and maximum number of items returned.
Attribute
Description
Default
order=""
ASC or DESC
DESC
orderby=""
date, title, or rand
date
posts=""
Limit items to value posts="10", shows 10 items posts="20", shows 20 items
-1
Layout
Select the template
Attribute
Description
Default
layout=""
horizontal, horizontal responsive cards grid, vertical grid column cards, required for products overlay, card-overlay (hero) custom, empty template to allow to create custom loop via action hooks
The context="" attribute is a powerful tool to create unlimited custom loop variants and apply filters in a conditional way. Use it like CSS classes without a comma separator.
hide-category, removes the category badge hide-meta, removes the meta date, author, comment etc. hide-meta-date-updated, removes the updated date hide-meta-author, removes the author hide-excerpt, removes the excerpt hide-read-more, removes the read-more link hide-tags, removes the tags badge hide-meta-wrapper, removes both category badge and sticky post badge
Not working in default horizontal layout truncate-heading, adds text-truncate to headings truncate-excerpt, adds text-truncate to the excerpt
Show a grid of taxonomy terms instead of single posts.
layout="overlay" is not recommended for taxonomies without a term thumbnail (see note above) — the card can render with zero height. Stick to horizontal (default) or grid for category/post_tag/custom taxonomies unless you’ve set up term thumbnails.
A classic unisex t-shirt that works well with any outfit. Made of a heavier cotton with a double-stitched neckline and sleeves. Rolled-forward shoulders for a better fit Stylish fitted sleeve Seamless double-needle collar Taped neck and shoulders for durability Tubular fit for minimal torque Logo print 8x8cm This product is made on demand. No minimums. […]
A classic unisex t-shirt that works well with any outfit. Made of a heavier cotton with a double-stitched neckline and sleeves. Rolled-forward shoulders for a better fit Stylish fitted sleeve Seamless double-needle collar Taped neck and shoulders for durability Tubular fit for minimal torque Logo print 8x8cm This product is made on demand. No minimums. […]
Show a grid of taxonomy terms (e.g. WooCommerce product categories) instead of products.
Only type="product_cat" uses an own template. All other taxonomies like product_brand and product_tag uses the default layout="horizontal/grid/overlay" templates.
Use layout="custom" together with context="" to build fully custom card designs via action hooks — without touching theme templates. Each example below is self-contained and only runs when its specific context is active.