• Resolved marksalvatore

    (@marksalvatore)


    I’m using Advance Custom Fields (ACF) with a Custom Post Type (CPT). The fields I set with ACF display only after the user selects a specific category. That’s problematic, since it depends on the user being obedient and first selecting the correct category before entering content for the post. I think that’s too much to ask, so I’d rather select that category for them, thus immediately displaying the set of fields I set up for that CPT. Ideally, that specific category would be assigned when the user clicks “Add new” (custom post type). But how is that done?

    I guess I could do this with javascript, but looking how others might have approached this same problem.

Viewing 1 replies (of 1 total)
  • Thread Starter marksalvatore

    (@marksalvatore)

    There’s a setting in ACFs to associated the field group to a CPT. This will result in having only those fields display when a new CPT is created.

Viewing 1 replies (of 1 total)
  • The topic ‘Assign a category upon creating new instance of custom post type’ is closed to new replies.