Using advanced custom fields from one custom post type in another custom post type

enter image description here

I have 2 custom post types, project and person. Both have several custom fields.
I’m working on a template for the project custom post type.

In the project custom fields I have several fields of type relation, as seen in this screenshot. Unfortunately I don’t really undestand what they mean and how to use them, but that is not my main question.

Next, inside the person custom fields, I have only text fields, like first_name, last_name, etc.

Now let’s say I have one custom post type of type person. That person has contributed to a project, which is a custom post type of type project.

How can I now, when working on the template of the project posts, include an [acf field] shortcode to a custom field of type person?

Here is a screenshot/concept of what I want to do: Circled in red are information pulled from the project custom fields, whereas circled in blue are information pulled from the person custom fields.

Notes:

  • I’m fairly new to wordpress and have no knowledge in php

  • Ideally a solution to my problem should not need me to add code to php files as that is not desired by my client. Preferably it should be doable inside the WPBakery template editor.

    • Installed and usable plugins are ACF, WPBakery, toolset, salient, acf-vc, custom post type UI

Thank you for your help, I hope I succeeded to phrase my problem in an understandable manner.

Read more here:: Using advanced custom fields from one custom post type in another custom post type

Leave a Reply

Your email address will not be published. Required fields are marked *