the_content
The WordPress Core the content hook.
Description
Parameters (2)
- 0. $array
- The array.
- 1. $priority (unknown)
- The priority.
Usage
- To run the hook, copy the example below.
- $array = apply_filters( 'the_content', $array, $priority );
- if ( !empty( $array ) ) {
- // everything has led up to this point...
- }
- The following example is for adding a hook callback.
- // define the the_content callback
- function filter_the_content( $array, $priority ) {
- // make filter magic happen here...
- return $array;
- };
- // add the filter
- add_filter( 'the_content', 'filter_the_content', 10, 2 );
- To remove a hook callback, use the example below.
- // remove the filter
- remove_filter( 'the_content', 'filter_the_content', 10, 2 );
Defined (4)
The filter is defined in the following location(s).
- /classes/class-s2-core.php
- remove_filter('the_content', array(&$wp_embed, 'autoembed'), $priority);
- $content = apply_filters('the_content', $content);
- add_filter('the_content', array(&$this, 'confirm'));
- add_filter('the_content', array(&$this, 'filter'), 10);