edd_after_download_content

After Download Content.

Description

(string) edd_after_download_content( $content ); 

Adds an action to the end of download post content that can be hooked to by other functions.

Returns (string)

the content with any additional data attached

Parameters (1)

0. $content
The the_content field of the download object

Usage

  1. if ( !function_exists( 'edd_after_download_content' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'easy-digital-downloads/includes/template-functions.php'; 
  3.  
  4. // The the_content field of the download object 
  5. $content = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = edd_after_download_content($content); 
  9.  

Defined (1)

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

/includes/template-functions.php  
  1. function edd_after_download_content( $content ) { 
  2. global $post; 
  3.  
  4. if ( $post && $post->post_type == 'download' && is_singular( 'download' ) && is_main_query() && !post_password_required() ) { 
  5. ob_start(); 
  6. do_action( 'edd_after_download_content', $post->ID ); 
  7. $content .= ob_get_clean(); 
  8.  
  9. return $content;