Home › Forums › General Issues › Taxonomy for custom field group › Reply To: Taxonomy for custom field group
Hi @bosoxbill
You need to add the taxonomy option so it looks like this:
'post_type' => array (
0 => 'game',
),
'taxonomy' => array (
0 => 'taxonomy_name:term_name',
),
Where “taxonomy_name” is the name of the taxonomy and “term_name” is the name of the term (baseball).
If you want, you can always create a Page Link field from the backend and export it to PHP code from “Custom Fields > Tools” (PRO version) or “Custom Fields > Export” (Free version). That way you can see the code layout you need to update your code.
I hope this helps 🙂
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.