5th Aug '24
/
0 comments

Filtering ACF Repeater Rows in Bricks by a Boolean Sub Field

Consider the following "Feature Table" ACF (Pro is needed) field group:

Sample Page with the Repeater populated:

Structure in Bricks editor:

with each column having the same ACF Repeater query loop.

After implementing the tutorial:

So essentially the requirement is to limit the ACF Repeater query loops in the three columns to only those rows for which the specified sub field - basic or business or professional is true respectively.

This Pro tutorial shows how.

Step 1

Set up the field group.

Here's the json export from our dev site.

Step 2

Edit a post of the post type for which the field group is set. Ex.: a Page

Add your features (3 in this example) and for each select what user group/product purchase/membership etc. is associated with it.

Step 3

Edit your Page or the template with Bricks.

This is a BricksLabs Pro tutorial.

For full access login below or create your BricksLabs Pro account

Get access to all 610 Bricks code tutorials with BricksLabs Pro

Related Tutorials..

Pro
Limit Bricks Users Query to Current Post’s User-type ACF Field Value

Limit Bricks Users Query to Current Post’s User-type ACF Field Value

Consider this scenario with ACF: "John Briley" user: "Gandhi" movie: The requirement is to show John Briley as the author when Gandhi movie item is…
Categories:
Adding any Custom WP_Query loop to Bricks’ Query Loop

Adding any Custom WP_Query loop to Bricks’ Query Loop

Sometimes we may need to create a custom post loop using Bricks' query loop feature, but wish to use our own WP_Query code for more…
Pro
Programmatically populating ACF field values in WordPress

Programmatically populating ACF field values in WordPress

An example of how to set the values of a Select-type field with the names and labels of all public post types.
Categories: