WP_REST_Posts_Controller::protected_title_format(): string

In this article

Overwrites the default protected and private title format.

Description

By default, WordPress will show password protected or private posts with a title of "Protected: %s" or "Private: %s", as the REST API communicates the status of a post in a machine-readable format, we remove the prefix.

Return

string Title format.

Source

public function protected_title_format() {
	return '%s';
}

Changelog

VersionDescription
4.7.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.