Home › Forums › Backend Issues (wp-admin) › Alter field group settings per content type › Reply To: Alter field group settings per content type
How you are loading the json does not matter. acf/load_field_group is called after every field group is loaded.
I don’t know anything about $GLOBALS['post_type']
Is this set at the point that you are checking it? I don’t know, but I am going to assume that it isn’t and you’re probably going to need to find another way to determine the post type.
function toind_get_flexible_content( $field_group ) {
var_dump($GLOBALS['post_type']);
.................................
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.