Help Center

Making JetElements and JetTabs Widgets Dynamic with Query Builder

This guide explains how to turn static widgets into dynamic, data-driven elements. You will learn how to connect widgets to queries so they can display content automatically based on your site’s structure and data sources.

Before you start, check the tutorial requirements:

JetEngine’s Query Builder module adds dynamics and flexibility to JetElements’ and JetTabs’ widgets, which are initially static. Modern websites often rely on dynamic functionality. Adding flexibility to new widgets improves content scalability, reduces manual work, and ensures consistent data output across the website. By connecting widgets to Query Builder, you can dynamically populate their content with posts, meta fields, relations, or custom query results, making them fully adaptable to different use cases and data structures.

Tabs for Posts

To display the dedicated posts in the Tabs widget dynamically, first of all, create a “Posts Query”. For that, proceed to WordPress Dashboard > JetEngine > Query Builder and click the “Add New” button.

Give a Name to the query and select the “Posts Query” Type. Set the needed Post Type and select the Post Status (“Published (publish)”). 

query for the listing for tabs with posts

Proceed to the Post & Page tab, click the “Dynamic Tag” icon next to the Posts In field, and select the “Current ID” option.

current id selected for the posts in

Save the query. 

Proceed to WordPress Dashboard > JetEngine > Listings/Components and click the “Add New Item” button.

Build the Listing Template, which will be displayed inside the Tabs.

listing for the tabs for posts

Click the “Publish” button once you are ready. 

Now, move to the Elementor templates and create a new one.  Select the “Page” type and enter the name for your template. 

Then, click the “Create Template” button. 

template for the tabs for posts

On the newly opened template editing page, add the Listing Grid widget. In the General > Listing field, select the template you have created. 

listing added to the template

Open the Custom Query tab and enable the Use Custom Query toggle. Select the Custom Query you have created. The listing may show the “No data was found” message, but it is okay on this step. Go on and save the settings.

query applied to the listing for tabs for posts

Now, create one more “Posts Query” for the same CPT.

query for the tabs widget for posts

Add any additional desired settings to the query if needed — here, you specify which posts will be shown in the Tabs (we specified the required posts by their IDs in the Post & Page > Post In field).

posts in for the query for the tabs for posts

Save the query. 

Go to the page where you need to display the Tabs, then add the Tabs widget to it. Enable the Use JetEngine query toggle and in the Select Query field, choose the last query you created. 

Ensure that you have only one Item. For the Content Type, select the “Template” option, then in the Choose Template field, pick the template you created. 

tabs for posts added to the page

Publish the page and check the front end. The Tabs with the selected six posts are displayed.

tabs for posts on the front

Terms Tabs for Posts

Now, we will investigate how to dynamically display the posts classified by the terms in the Tabs

First, create a “Posts Query”. For that, proceed to WordPress Dashboard > JetEngine > Query Builder and click the “Add New” button. Enter the query Name and select the “Posts Query” Type

Choose the needed Post Type in the General settings tab. 

query for the listing for the tabs for posts of terms

Move to the Tax Query tab and click the “Add new” button. Select the needed Taxonomy and the “Term ID” option in the Field input. Next to the Terms field, click the “Dynamic Tag” icon and select the “Queried term” option. Choose the “IN” option for the Compare operator

tax query in the posts query for the tabs for posts of terms

Click the “Add Query” button once you are ready.

Build a Listing Template proceeding to WordPress Dashboard > JetEngine > Listings/Components

listing for the tabs for posts of terms

Save the Listing Template

Then, create an Elementor template to display in the Tabs. In the template, add the Listing Grid widget and apply the query you created.

listing added to the template for the tabs for posts of terms

Save the template.

Then, create a “Terms Query”. Move to WordPress Dashboard > JetEngine > Query Builder and click the “Add New” button. Enter the Query Name and select the “Terms Query” Type

Select the Taxonomy in the General tab and save the query.

terms query for tabs for posts of terms

Go to the page where the Tabs will be displayed. Add the Tabs widget and enable the Use JetEngine query toggle. Select the “Terms Query” you created. 

Ensure that one Item only is added. To display the terms as the tabs’ names, click the “Dynamic Tag” icon next to the Label field. Select the “Term Field” option, and in the newly opened pop-up, select the Taxonomy and the “Term name” option as the Field.

label set up for tabs for posts of terms

Ensure that the “Template” option is selected for the Content Type. In the Choose Template field, select the template you created. Save the page. 

On the front end, you get tabs with posts classified by terms.

tabs for posts of terms on the front

Tabs for Parent and Child Terms

Now, we will create Tabs with child terms, divided by parent terms. 

First, create a “Terms Query” by going to WordPress Dashboard > JetEngine > Query Builder and clicking the “Add New” button. 

Select the needed Taxonomy in the General tab.

terms query for listing for tabs for parent and child terms

Move to the Parent/Child tab and in the Parent field select the “Queried term” option after clicking the “Dynamic Tag” icon.

parent field set up in terms query for listing for tabs for parent and child terms

Click the “Add Query” button.  

Now, create a Listing Template for the children terms. For that, proceed to WordPress Dashboard > JetEngine > Lisings/Components. Click the “Add new item” button. 

terms listing for tabs for parent and child terms

Publish the Listing Template and proceed to Elementor to create a “Page” template. In the template, add the Listing Grid widget and select the Listing you created. Apply the “Terms Query” you created to the Listing Grid

template for tabs for parent and child terms

Then create another “Terms Query” for the same Taxonomy. After adding the Name, Query Type, and selecting the Taxonomy in the General tab, proceed to the Parent/Child tab and put “0” in the Parent field. 

terms query for tabs for parent and child terms

Click the “Add Query” button once you are ready. 

Move to the page and add the Tabs widget. Turn on the Use JetEngine query toggle and select the latest “Terms Query” you created. 

Ensure that one Item only is added. To display the parents’ terms as the tabs’ names, click the “Dynamic Tag” icon next to the Label field. Select the “Term Field” option, and in the newly opened pop-up, select the Taxonomy and the “Term name” option.

Choose the “Template” option for the Content Type. In the Choose Template field, select the template you created. Save the page. 

set up for tabs for parent and child terms

On the frontend page, you get tabs with children terms classified by parent terms.

tabs for parent and child terms on the front

Slider for Posts

To display posts in the Slider dynamically, create a “Posts Query” to return posts from the needed CPT

For that, move to WordPress Dashboard > JetEngine > Query Builder and click the “Add New” button.

Enter a Name for the query and select “Posts Query” as the Query Type. In the Post Type field of the General tab, choose the needed CPT.

query for the sliders for posts

You can add any other needed settings and save the query. 

Go to the page where you need to display the slider, then add the Slider widget. Enable the Use JetEngine query toggle and select the query you created. 

Ensure that one Item only is kept. To display data from the posts, click the “Dynamic Tag” icon next to the needed fields and select the needed “Custom Field”. 

slider settings to display posts dynamically

Once you are ready, publish the page and check the frontend. Here, we dynamically load the selected posts into the Slider widget.

slider displays posts dynamically on the front

Testimonials for Posts

To dynamically display the posts in the Testimonials widgets, first build a “Posts Query”. It can be a query that returns posts of the dedicated CPT.

For that, proceed to WordPress Dashboard > JetEngine > Query Builder and click the “Add New” button.

Enter a Name for the query and select “Posts Query” as the Query Type. In the Post Type field of the General tab, choose the required CPT.

query for the testimonials for posts

Add any other settings you need to the query and save it. 

Proceed to the page where the data should be displayed. Add the Testimonials widget and enable the Use JetEngine query toggle. Select the query that was created before. 

Keep one Item only. Then, to display the posts’ data, click the “Dynamic Tag” icon next to the field we need to fill in, select the “Custom Field” option, and choose the desired field. 

testimonials for posts set up

Save the changes when you are ready, then check the frontend. 

Here, we dynamically display the Testimonials with the posts.

testimonials for posts on the front

Vertical Timeline for Posts

To dynamically pull posts into the Vertical Timeline widget, you first need to create a “Posts Query”.

Navigate to WordPress Dashboard > JetEngine > Query Builder and click the “Add New” button.

Enter a Name for the query and select “Posts Query” as the Query Type. In the Post Type field of the General tab, choose the required CPT.

posts query for the vertical timeline widget for posts

Adjust additional query settings if needed.

Click “Add Query” to save the changes.

Proceed to the page where you need to display the data and open it in Elementor. Locate the Vertical Timeline widget.

In the Cards tab of the widget settings, enable the Use JetEngine query toggle. Select the custom query created earlier.

Leave only one Card and remove the rest. This card will act as a template for dynamically loaded items.

To dynamically pull data from posts, use “Dynamic Tags” for the widget fields. Click the “Dynamic Tags” icon and select the “Custom Field” option. Choose the required meta field.

vertical timeline for posts settings

Once finished, click “Publish to save the page. Open it on the front end to check how it works.

vertical timeline for posts on the front

That’s it. Now you know how to make Tabs, Slider, Testimonials, and Vertical Timeline widgets from JetElements and JetTabs be updated dynamically using the JetEngine’s Query Builder module on the WordPress site. 

Was this article helpful?
YesNo

Need help?

Ask Facebook community

Get answers from 30K+ Crocoblock Community experts from all over the world.

Start a live chat

Ask question to support agent and share its details via chat messages.