edd_add_download_meta_box

Register all the meta boxes for the Download custom post type.

Description

edd_add_download_meta_box(); 

Usage

  1. if ( !function_exists( 'edd_add_download_meta_box' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'easy-digital-downloads/includes/admin/downloads/metabox.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = edd_add_download_meta_box(); 
  7.  

Defined (1)

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

/includes/admin/downloads/metabox.php  
  1. function edd_add_download_meta_box() { 
  2.  
  3. $post_types = apply_filters( 'edd_download_metabox_post_types' , array( 'download' ) ); 
  4.  
  5. foreach ( $post_types as $post_type ) { 
  6.  
  7. /** Product Prices **/ 
  8. add_meta_box( 'edd_product_prices', sprintf( __( '%1$s Prices', 'easy-digital-downloads' ), edd_get_label_singular(), edd_get_label_plural() ), 'edd_render_download_meta_box', $post_type, 'normal', 'high' ); 
  9.  
  10. /** Product Files (and bundled products) **/ 
  11. add_meta_box( 'edd_product_files', sprintf( __( '%1$s Files', 'easy-digital-downloads' ), edd_get_label_singular(), edd_get_label_plural() ), 'edd_render_files_meta_box', $post_type, 'normal', 'high' ); 
  12.  
  13. /** Product Settings **/ 
  14. add_meta_box( 'edd_product_settings', sprintf( __( '%1$s Settings', 'easy-digital-downloads' ), edd_get_label_singular(), edd_get_label_plural() ), 'edd_render_settings_meta_box', $post_type, 'side', 'default' ); 
  15.  
  16. /** Product Notes */ 
  17. add_meta_box( 'edd_product_notes', sprintf( __( '%1$s Notes', 'easy-digital-downloads' ), edd_get_label_singular(), edd_get_label_plural() ), 'edd_render_product_notes_meta_box', $post_type, 'normal', 'high' ); 
  18.  
  19. if ( current_user_can( 'view_product_stats', get_the_ID() ) ) { 
  20. /** Product Stats */ 
  21. add_meta_box( 'edd_product_stats', sprintf( __( '%1$s Stats', 'easy-digital-downloads' ), edd_get_label_singular(), edd_get_label_plural() ), 'edd_render_stats_meta_box', $post_type, 'side', 'high' );