acf/update_(hook_name) хук-событиеACF 6.1

Fires immediately after an ACF post has been updated.

Использование

add_action( 'acf/update_(hook_name)', 'wp_kama_acf_update_hook_name_action' );

/**
 * Function for `acf/update_(hook_name)` action-hook.
 * 
 * @param array $post The main ACF post array.
 *
 * @return void
 */
function wp_kama_acf_update_hook_name_action( $post ){
	// action...
}
$post(массив)
The main ACF post array.

Список изменений

С версии 6.1 Введена.

Где вызывается хук

ACF_Internal_Post_Type::update_post()
acf/update_(hook_name)
acf/includes/class-acf-internal-post-type.php 533
do_action( "acf/update_{$this->hook_name}", $post );

Где используется хук в Advanced Custom Fields PRO

acf/includes/local-json.php 51
add_action( 'acf/update_field_group', array( $this, 'update_field_group' ) );
acf/includes/local-json.php 55
add_action( 'acf/update_post_type', array( $this, 'update_internal_post_type' ) );
acf/includes/local-json.php 59
add_action( 'acf/update_taxonomy', array( $this, 'update_internal_post_type' ) );
acf/pro/post-types/acf-ui-options-page.php 287
add_action( 'acf/update_ui_options_page', array( $local_json, 'update_internal_post_type' ) );