Post Loop Builder
The Post Loop Builder repeats one component once per post — a blog index, a related-posts
row, a grid of products or team members. You choose the component and the query; it renders
one item per result. Post Loops is the guide to building with it;
this page is the element's controls.
Repeated Block
- Component — the component rendered once per post. Until you pick one, each item
renders "Choose a Component from the dropdown." Edit Component opens it in the builder. - Tag — the HTML tag each item is wrapped in:
article(the default),section, or
div. - Advanced opens a popout with three things, each covered in the Loops section:
- Alternates — a different component at a given position, optionally repeating on a
frequency. See Alternate & Static Items. - Static Items — a component inserted at a position without consuming a post, again
with an optional repeat frequency. Same article. - When Empty — the component rendered instead of the loop when the query returns
nothing. See Empty State.
- Alternates — a different component at a given position, optionally repeating on a
Query
One control: the query builder, which decides which posts the loop renders — post types,
taxonomies, ordering, and the rest.
Post Loops covers the common cases, and
Queries covers writing one by hand.
Pagination
- Pagination — None, Numbers, Previous / Next, Numbers + Previous /
Next, Load More Button, or Infinite Scroll. - Previous Text / Next Text — the link labels, for the two modes that show them.
- Show All Page Numbers — for the numbered modes.
- Load More Text — the button's label, for Load More.
The whole section is hidden while the Filter Bar is enabled — the two are alternatives.
Pagination has the detail.
Filter Bar
A row of taxonomy filters above the loop that filters the rendered items in the browser.
- Enable — off by default; everything below appears once it's on.
- Type — which taxonomy the filters come from.
- All Filter — adds an "all" button, and All Label sets its text.
- Sort By — Name (A-Z), Name (Z-A), Term Order, or Count.
- Hide Uncategorized — leaves the Uncategorized term out of the row.
On the front end
The element renders a div.bde-post-loop containing a div.bde-loop wrapper, and inside it
one element per post using the Tag you chose, each carrying bde-loop-item plus the
usual WordPress post classes. The component's markup is rendered inside each item. Pagination
markup, when enabled, follows the wrapper.
Related elements
- Term Loop Builder — the same thing for taxonomy
terms. - Repeater Field — the same thing for the rows of a
repeater custom field. - Component — renders a component once, rather than once
per item.