sharing_meta_box_content

The Jetpack by WordPress.com sharing meta box content function.

Description

sharing_meta_box_content( $post ); 

Parameters (1)

0. $post
The post.

Usage

  1. if ( !function_exists( 'sharing_meta_box_content' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'jetpack-by-wordpress-com/modules/sharedaddy/sharedaddy.php'; 
  3.  
  4. // The post. 
  5. $post = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = sharing_meta_box_content($post); 
  9.  

Defined (1)

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

/modules/sharedaddy/sharedaddy.php  
  1. function sharing_meta_box_content( $post ) { 
  2. /** 
  3. * Fires before the sharing meta box content. 
  4. * @module sharedaddy 
  5. * @since 2.2.0 
  6. * @param WP_Post $post The post to share. 
  7. */ 
  8. do_action( 'start_sharing_meta_box_content', $post ); 
  9.  
  10. $disabled = get_post_meta( $post->ID, 'sharing_disabled', true ); ?> 
  11.  
  12. <p> 
  13. <label for="enable_post_sharing"> 
  14. <input type="checkbox" name="enable_post_sharing" id="enable_post_sharing" value="1" <?php checked( !$disabled ); ?>> 
  15. <?php _e( 'Show sharing buttons.' , jetpack); ?> 
  16. </label> 
  17. <input type="hidden" name="sharing_status_hidden" value="1" /> 
  18. </p> 
  19.  
  20. <?php 
  21. /** 
  22. * Fires after the sharing meta box content. 
  23. * @module sharedaddy 
  24. * @since 2.2.0 
  25. * @param WP_Post $post The post to share. 
  26. */ 
  27. do_action( 'end_sharing_meta_box_content', $post );