Support

Account

Home Forums General Issues Need help with save_post hook Reply To: Need help with save_post hook

  • Hi @Spinal

    The easiest way is to use the get_field function to load any data (even in the save_post action!)

    Make sure you run your code AFTER ACF has saved, like so:

    
    <?php 
    
    add_action('acf/save_post', 'function_name', 20);
    
    function function_name( $post_id )
    {
    	$new_val = get_field('field_name', $post_id);
    }
    
     ?>