image_attachment_fields_to_edit

Retrieves the image attachment fields to edit form fields.

Description

(array) image_attachment_fields_to_edit( (array) $form_fields, (object) $post ); 

Returns (array)

Parameters (2)

0. $form_fields (array)
The form fields.
1. $post (object)
The post.

Usage

  1. if ( !function_exists( 'image_attachment_fields_to_edit' ) ) { 
  2. require_once ABSPATH . '/wp-admin/includes/media.php'; 
  3.  
  4. // The form fields. 
  5. $form_fields = array(); 
  6.  
  7. // The post. 
  8. $post = null; 
  9.  
  10. // NOTICE! Understand what this does before running. 
  11. $result = image_attachment_fields_to_edit($form_fields, $post); 
  12.  

Defined (1)

The function is defined in the following location(s).

/wp-admin/includes/media.php  
  1. function image_attachment_fields_to_edit($form_fields, $post) { 
  2. return $form_fields;