# Loop over deeply nested meta box clonable field inside query

**URL:** <https://forum.bricksbuilder.io/t/loop-over-deeply-nested-meta-box-clonable-field-inside-query/28081>\
**Category:** How To\
**Tags:** how-to\
**Created:** [November 19, 2024, 8:40pm UTC](https://forum.bricksbuilder.io/t/loop-over-deeply-nested-meta-box-clonable-field-inside-query/28081 "2024-11-19T20:40:24Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![waysagency](https://forum.bricksbuilder.io/user_avatar/forum.bricksbuilder.io/waysagency/32/21492_2.png) [@waysagency](https://forum.bricksbuilder.io/u/waysagency)\
**Post date:** [November 19, 2024, 8:40pm UTC](https://forum.bricksbuilder.io/t/loop-over-deeply-nested-meta-box-clonable-field-inside-query/28081/1 "2024-11-19T20:40:24Z")

</div>

Hi guys,

I’m trying to loop over a clonable meta box field that is inside a couple of groups.

For example:  
Main category → Subcategory → menu item (food) → prices (clonable)

Of course the groups are easy, they are supported, but I don’t really know how to loop over the nested clonable field.

Any thought or examples how to do that?

---

<div class="post-metadata">

**Author:** ![SuatB](https://forum.bricksbuilder.io/user_avatar/forum.bricksbuilder.io/suatb/32/22666_2.png) [@SuatB](https://forum.bricksbuilder.io/u/SuatB)\
**Post date:** [November 22, 2024, 4:09pm UTC](https://forum.bricksbuilder.io/t/loop-over-deeply-nested-meta-box-clonable-field-inside-query/28081/2 "2024-11-22T16:09:09Z")

</div>

I don’t think this is completly possible inside the builder. I would guess you would need to use some of the bricks filters.

These filters are extremle powerful, and should get the job done, but honestly I can’t say how without doing it myself.

But i would probably try to create my own query-type and write some dynamic-data-tags that output these custom fields.

Create your own query-type and it’s logic:

> **[Filter: bricks/query/run](https://academy.bricksbuilder.io/article/filter-bricks-query-run/)**
>
> The Bricks Query Loop supports 3 types of queries by default (Posts, Terms and Users). But it can be extended to support any other query. To return a custom query result, Bricks can be extended using the WP filter bricks/query/run like so: The filter...

But you need to be able to select it within the builder, so you setup a control for it:

> **[Filter: bricks/setup/control\_options](https://academy.bricksbuilder.io/article/filter-bricks-setup-control_options/)**
>
> Bricks offers a WordPress filter to add or remove control options. The control options are used throughout Bricks and allow you to manage the options of the: Template Types (e.g. Header, Footer, Single, Section…) Background position, repeat,...

Create dynamic data-tag for within your custom-query:

> **[Create Your Own Dynamic Data Tag](https://academy.bricksbuilder.io/article/create-your-own-dynamic-data-tag/)**
>
> This article is intended for developers who wish to create a custom dynamic data tag within the builder. The desired outcome should resemble the following example: Step 1: Register a tag through filter: bricks/dynamic\_tags\_list Use the...

Hope this nudges you in the right direction  
Cheers
