apply_filters( 'protected_title_format', string $prepend , WP_Post $post )
Filters the text prepended to the post title for protected posts.
Description
The filter is only applied on the front end.
Parameters
-
$prepend
string -
Text displayed before the post title.
Default 'Protected: %s'. -
$post
WP_Post -
Current post object.
Source
File: wp-includes/post-template.php
.
View all references
$protected_title_format = apply_filters( 'protected_title_format', $prepend, $post );
Changelog
Version | Description |
---|---|
2.8.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.
Example migrated from Codex:
Remove protected prefix from post titles
Top ↑
Feedback
This didn’t work for me on 5.7.2. No change to the title. — By revive —