Viewing 1 replies (of 1 total)
  • Plugin Author Konrad Chmielewski

    (@hwk-fr)

    Hello,

    Thanks for the feedback!

    If you need to remove/set new terms during a Post Action in the ACF Extended Form module, you should use the acfe/form/submit/post hook. See documentation. This hook will let you perform an action right after a post creation/update. Usage example:

    add_action('acfe/form/submit/post/form=my-form', 'my_form_submit', 10, 5);
    function my_form_submit($post_id, $type, $args, $form, $action){
        
        wp_remove_object_terms($post_id, 'uncategorized', 'category');
        
    }
    

    Hope it helps!

    Have a nice day!

    Regards.

Viewing 1 replies (of 1 total)
  • The topic ‘How do I remove default category in WordPress automatically?’ is closed to new replies.