wp_privacy_additional_user_profile_data WordPress Filter Hook

The wp_privacy_additional_user_profile_data hook allows you to add additional user profile data to the WordPress Privacy Policy page. This hook is useful if you have custom user fields that you want to include in the Privacy Policy.

apply_filters( 'wp_privacy_additional_user_profile_data', array $additional_user_profile_data, WP_User $user, string[] $reserved_names ) #

Filters the user’s profile data for the privacy exporter.


Parameters

$additional_user_profile_data

(array)An array of name-value pairs of additional user data items. Default empty array.

  • 'name'
    (string) The user-facing name of an item name-value pair,e.g. 'IP Address'.
  • 'value'
    (string) The user-facing value of an item data pair, e.g. '50.60.70.0'.

$user

(WP_User)The user whose data is being exported.

$reserved_names

(string[])An array of reserved names. Any item in $additional_user_data that uses one of these for its name will not be included in the export.


Top ↑

Source

File: wp-includes/user.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
5.4.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More