Support

Account

Home Forums General Issues Subheadline Text Delayed when Publishing? Reply To: Subheadline Text Delayed when Publishing?

  • Hi @Nitruc

    I think you have miss-understood my advice with this one.

    Looking at your code, I can see that your function ‘custom_post_title’ is not actually doing anything, yest you are still using the ‘wp_insert_post_data’ action to do your logic.

    What I have tried to explain is that you SHOULDNT use the wp_insert_post_data action, but instead use the update_value filter instead.

    An action or a filter is a point in time where you can run some custom functionality. As stated previously, the wp_insert_post_data action is TOO EARLY to work correctly. You need to use the acf filter instead to get the latest ACF values and then use a wp_update_post function to modify the $post object.

    I hope you understand this.

    Thanks
    E