wp_edit_form_attachment_display
Action HookDescription
Fires when an attachment type can't be rendered in the edit form.Hook Information
File Location |
wp-admin/includes/media.php
View on GitHub
|
Hook Type | Action |
Line Number | 3230 |
Hook Parameters
Type | Name | Description |
---|---|---|
WP_Post
|
$post
|
A post object. |
Usage Examples
Basic Usage
<?php
// Hook into wp_edit_form_attachment_display
add_action('wp_edit_form_attachment_display', 'my_custom_function', 10, 1);
function my_custom_function($post) {
// Your custom code here
}
Source Code Context
wp-admin/includes/media.php:3230
- How this hook is used in WordPress core
<?php
3225 *
3226 * @since 4.6.0
3227 *
3228 * @param WP_Post $post A post object.
3229 */
3230 do_action( 'wp_edit_form_attachment_display', $post );
3231
3232 endif;
3233
3234 ?>
3235 </div>
PHP Documentation
<?php
/**
* Fires when an attachment type can't be rendered in the edit form.
*
* @since 4.6.0
*
* @param WP_Post $post A post object.
*/
Quick Info
- Hook Type: Action
- Parameters: 1
- File: wp-admin/includes/media.php
Related Hooks
Related hooks will be displayed here in future updates.