Filters attachment post data before it is updated in or added to the database.
Parameters
$data
array- An array of slashed, sanitized, and processed attachment post data.
$postarr
array- An array of slashed and sanitized attachment post data, but not processed.
$unsanitized_postarr
array- An array of slashed yet *unsanitized* and unprocessed attachment post data as originally passed to wp_insert_post() .
$update
bool- Whether this is an existing attachment post being updated.
Source
$data = apply_filters( 'wp_insert_attachment_data', $data, $postarr, $unsanitized_postarr, $update );
User Contributed Notes
You must log in before being able to contribute a note or feedback.