[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-admin/includes/ -> class-wp-privacy-policy-content.php (summary)

WP_Privacy_Policy_Content class.

File Size: 700 lines (32 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 10 functions

  __construct()
  add()
  text_change_check()
  policy_text_changed_notice()
  _policy_page_updated()
  get_suggested_policy_text()
  notice()
  privacy_policy_guide()
  get_default_content()
  add_suggested_content()

Functions
Functions that are not part of a class:

__construct()   X-Ref
Constructor

since: 4.9.6

add( $plugin_name, $policy_text )   X-Ref
Add content to the postbox shown when editing the privacy policy.

Plugins and themes should suggest text for inclusion in the site's privacy policy.
The suggested text should contain information about any functionality that affects user privacy,
and will be shown in the Suggested Privacy Policy Content postbox.

Intended for use from `wp_add_privacy_policy_content()`.

param: string $plugin_name The name of the plugin or theme that is suggesting content for the site's privacy policy.
param: string $policy_text The suggested content for inclusion in the policy.
since: 4.9.6

text_change_check()   X-Ref
Quick check if any privacy info has changed.

since: 4.9.6

policy_text_changed_notice()   X-Ref
Output a warning when some privacy info has changed.

since: 4.9.6

_policy_page_updated( $post_id )   X-Ref
Update the cached policy info when the policy page is updated.

param: int $post_id The ID of the updated post.
since: 4.9.6

get_suggested_policy_text()   X-Ref
Check for updated, added or removed privacy policy information from plugins.

Caches the current info in post_meta of the policy page.

return: array The privacy policy text/information added by core and plugins.
since: 4.9.6

notice( $post = null )   X-Ref
Add a notice with a link to the guide when editing the privacy policy page.

param: WP_Post|null $post The currently edited post. Default null.
since: 4.9.6
since: 5.0.0 The `$post` parameter was made optional.

privacy_policy_guide()   X-Ref
Output the privacy policy guide together with content from the theme and plugins.

since: 4.9.6

get_default_content( $description = false, $blocks = true )   X-Ref
Return the default suggested privacy policy content.

param: bool $description Whether to include the descriptions under the section headings. Default false.
param: bool $blocks      Whether to format the content for the block editor. Default true.
return: string The default policy content.
since: 4.9.6
since: 5.0.0 Added the `$blocks` parameter.

add_suggested_content()   X-Ref
Add the suggested privacy policy text to the policy postbox.

since: 4.9.6



Generated: Sun Dec 22 01:00:02 2024 Cross-referenced by PHPXref 0.7.1