woocommerce_format_content

Format content to display shortcodes.

Description

(string) apply_filters( 'woocommerce_format_content', (unknown) $apply_filters, (unknown) $raw_string ); 

Returns (string)

Parameters (2)

0. $apply_filters (unknown) => apply_filters( 'woocommerce_short_description', $raw_string )
The apply filters.
1. $raw_string (unknown)
The raw string.

Usage

To run the hook, copy the example below.
  1. $apply_filters = apply_filters( 'woocommerce_format_content', $apply_filters, $raw_string ); 
  2.  
  3. if ( !empty( $apply_filters ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the woocommerce_format_content callback 
  2. function filter_woocommerce_format_content( $apply_filters, $raw_string ) { 
  3. // make filter magic happen here... 
  4. return $apply_filters
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'woocommerce_format_content', 'filter_woocommerce_format_content', 10, 2 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'woocommerce_format_content', 'filter_woocommerce_format_content', 10, 2 ); 

Defined (1)

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

/includes/wc-formatting-functions.php  
  1. return apply_filters( 'woocommerce_format_content', apply_filters( 'woocommerce_short_description', $raw_string ), $raw_string );