pfeifferNet

subscriber.php

Functions for subscribers capability.

  • A user has login credentials and is logged in.
  • Users with subscriber privileges can view private content.
Tags
since
5.6.0
copyright

2024 Keith Pfeiffer

Table of Contents

Functions

filter_private_title()  : string
Filters the text prepended to the post title of private posts.

Functions

filter_private_title()

Filters the text prepended to the post title of private posts.

filter_private_title(string $prepend, WP_Post $post) : string
  • Single pages or posts have no prepended text.
  • Prepend a subscriber-only notice everywhere else.
Parameters
$prepend : string

Text displayed before the post title. Default 'Private: %s'.

$post : WP_Post

Current post object.

Tags
since
5.6.0
link
https://developer.wordpress.org/reference/hooks/private_title_format/
Return values
string

The (maybe) modified prepend string.


        
On this page

Search results