Looper Provider by user email

Hi,

I have created a custom post with ACF Pro and want to pull data from one of those custom posts if an email field (contact_email) matches the email of the logged in user. Would Query String be the looper provider type to use in this case? I’ve tried {{dc:acf:post_field field=“contact_email”}}={{dc:user:email}} and it doesn’t seem to work.

Any suggestions?

Thanks,
Darren.

Hello Darren,

Thanks for writing in!

You will have to use the Looper Provider Query String and then your query string will probably be like this:
post_type=your_post_type&meta_key=contact_email&meta_value={{dc:user:email}}

Kindly let us know how it goes.

Hey Ruenel, that worked great - thank you!

I actually changed it to check the User ID instead and it works perfectly - thanks again.

I am still stuck on one thing though. I have a user registration form built in WP Forms that creates a new User and populates some custom fields in a new custom post called Client. There is a field called ClientID in the Client Custom Post that I want to set as the UserId upon adding the new User, so I can link that new post and other subsequent posts to that User.

Any suggestions on how I do that?

Cheers,
Darren.

Hey Darren,

We can’t provide help with CPTs as part of our theme support. That would be part of WordPress support which we can provide in our One service. Please consider subscribing to receive guidance on this matter.

Thanks.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.