Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: protected_title_format

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
112                 * Filter the text prepended to the post title for protected posts.
113                 *
114                 * The filter is only applied on the front end.
115                 *
116                 * @since 2.8.0
117                 *
118                 * @param string $prepend Text displayed before the post title.
119                 *                        Default 'Protected: %s'.
120                 */
121                $protected_title_format = apply_filters( 'protected_title_format', __( 'Protected: %s' ) );
122                $title = sprintf( $protected_title_format, $title );
123           } else if ( isset( $post->post_status ) && 'private' == $post->post_status ) {
124
125                /**
126                 * Filter the text prepended to the post title of private posts.
127                 *
128                 * The filter is only applied on the front end.
129                 *
130                 * @since 2.8.0