ACF/Meta Box Gallery Images as Bricks Slider Using a Custom Query Type in Bricks

For an easier alternative method, follow this tutorial instead.


Updated on 26 Jul 2023

This Pro tutorial provides the steps to set images of a ACF Pro's Gallery field or Meta Box' Image Advanced type of field as the source of a Slider (Nestable) element in Bricks.

When editing a Page:

When the Page is being viewed on the front end:

ACF Pro

Step 1

Create a field group having a Gallery-type of field labelled say, Page Gallery and set its location to be your desired post type (Pages in this example).

Step 2

Edit your Pages and populate the field for each by uploading/selecting your desired images that should appear in the slider.

Step 3

Add the following in child theme's functions.php (w/o the opening PHP tag) or a code snippets plugin:

This is a BricksLabs Pro tutorial.

For full access login below or create your BricksLabs Pro account

Get access to all 524 Bricks code tutorials with BricksLabs Pro

Related Tutorials..

Pro
Meta Box/ACF Images Staggered Grid Gallery in Bricks

Meta Box/ACF Images Staggered Grid Gallery in Bricks

Showing images from two Gallery-type of ACF or Image Advanced-type of Meta Box fields in a staggered grid layout.
Pro
Post-specific ACF Repeater Galleries as Sliders in Bricks

Post-specific ACF Repeater Galleries as Sliders in Bricks

How to output ACF Repeater field rows with the images of the Gallery-type sub field as a slider.