image_attachment_fields_to_save()
Deprecated from version 6.0.0. It is no longer supported and can be removed in future releases. It is recommended to replace this function with the same one.
Was used to filter input from media_upload_form_handler() and to assign a default post_title from the file name if none supplied.
No Hooks.
Return
Array
. Attachment post object converted to an array.
Usage
image_attachment_fields_to_save( $post, $attachment );
- $post(array) (required)
- The WP_Post attachment object converted to an array.
- $attachment(array) (required)
- An array of attachment metadata.
Changelog
Since 2.5.0 | Introduced. |
Deprecated since | 6.0.0 |
image_attachment_fields_to_save() image attachment fields to save code WP 6.6.2
function image_attachment_fields_to_save( $post, $attachment ) { _deprecated_function( __FUNCTION__, '6.0.0' ); return $post; }