Assign a category upon creating new instance of custom post type
-
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.
- The topic ‘Assign a category upon creating new instance of custom post type’ is closed to new replies.