wp_image_editor_before_change хук-фильтрWP 3.5.0

Filters the WP_Image_Editor instance before applying changes to the image.

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

add_filter( 'wp_image_editor_before_change', 'wp_kama_image_editor_before_change_filter', 10, 2 );

/**
 * Function for `wp_image_editor_before_change` filter-hook.
 * 
 * @param WP_Image_Editor $image   WP_Image_Editor instance.
 * @param array           $changes Array of change operations.
 *
 * @return WP_Image_Editor
 */
function wp_kama_image_editor_before_change_filter( $image, $changes ){

	// filter...
	return $image;
}
$image(WP_Image_Editor)
WP_Image_Editor instance.
$changes(массив)
Array of change operations.

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

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

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

image_edit_apply_changes()
wp_image_editor_before_change
wp-admin/includes/image-edit.php 695
$image = apply_filters( 'wp_image_editor_before_change', $image, $changes );

Где используется хук в WordPress

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