Archived topic
Query Loop Not Picking up Dynamic Data?
17 replies · Started by Tom on December 8, 2022
Hi,
Using the following:
- CPT UI
- Custom Fields
- Generate Press (Theme)
- Generate Press Premium
- Generate Blocks Pro
I then
- Created Custom Fields in a CPT.
- Created a PAGE with a container and Query Loop
- Enabled Dynamic Data and used custom field name in Post Meta
- And in the Query Loop - selected the CPT
But when I preview page - nothing appears. I am at a loss. Seemed easy enough. Do not know if I am missing something small or substantial.
Any help is appreciated!
Thank you.
Hi Tom,
Can you provide an admin login and point us to where we should be looking at?
See Customer Support information (Private Information)
The data source is not correctly chosen, try select the CPT as the data source instead of current post which is the static page:
https://www.screencast.com/t/PgkXdJ3dHIr
It only gives me the choice of:
- Current Post
- Post Type
It does not offer the choice of CPT as the Data Source?
Apologies if I am not following correctly.
Thank you.
Actually, I got confused, it should be the current post :) My bad!
I checked some of the single HLF team, the custom fields are still blank.
https://www.screencast.com/t/uCwJU8mychkL
Can you link me to one of the HLT team members that have all values ready so we can take that as an example?
Ying,
Wow. That is scary - I have lost the data on the 10 employees. That is why the results are empty.
Let me re-enter the data for a couple and see if that makes a difference.
Really concerned about where data went?
Will be back in a bit. Thanks.
Oh..that's wired, loosing data like that is very scary and annoying too.
Does the CPT have revisions? I hope so!
Okay - I put two team members back in and the information I want to show up does.
Except for the team member photo (which is NOT the featured image).
I looked around and could not figure out why.
photo_team_member
Could you take a look?
Thanks!
I have tried a half dozen things and still cannot get image to show up.
Hi Tom,
Can you try changing the Image field return format to the Image URL? Example: https://share.getcloudapp.com/rRu59bQ5
Let us know how it goes.
Hey Fernando,
No luck my friend. Don't know what the problem is.
Got it!
Took long enough. But I added a new image field - then used same parameter you suggested. Worked.
So - I don't know what happened with the initial attempt. *Possibly* - After I changed the "Name" I needed to reload the image element on the query loop.
Query loop questions:
1 - Any way to change the number of loop instances in a row from 2 to three?
2 - Any way at ALL to control the order of appearance?
I see. Glad it's working now. It might have been an ACF database issue. Good thinking on trying to recreate the field!
1. Set the Container Width of your Post Template Block to 33%. Example: https://share.getcloudapp.com/P8uNE60A
2. There's an order and order by parameter that you can set in your Query Loop Block. Example: https://share.getcloudapp.com/nOu189E9