Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: the_content

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
1848
1849           if ( rest_is_field_included( 'content', $fields ) ) {
1850                $data['content'] = array();
1851           }
1852           if ( rest_is_field_included( 'content.raw', $fields ) ) {
1853                $data['content']['raw'] = $post->post_content;
1854           }
1855           if ( rest_is_field_included( 'content.rendered', $fields ) ) {
1856                /** This filter is documented in wp-includes/post-template.php */
1857                $data['content']['rendered'] = post_password_required( $post ) ? '' : apply_filters( 'the_content', $post->post_content );
1858           }
1859           if ( rest_is_field_included( 'content.protected', $fields ) ) {
1860                $data['content']['protected'] = (bool) $post->post_password;
1861           }
1862           if ( rest_is_field_included( 'content.block_version', $fields ) ) {
1863                $data['content']['block_version'] = block_version( $post->post_content );
1864           }
1865
1866           if ( rest_is_field_included( 'excerpt', $fields ) ) {