wppaste
WordPress

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

Since
5.4.0
Filters the user's profile data for the privacy exporter.

Compatibility

WordPress
since 5.4.0
  • 6.7.7
  • 6.8.8
  • 6.9.7
  • 7.0.4
  • 7.1.0

Present in every tracked release (6.7.7 to 7.1.0).

Parameters

$additional_user_profile_dataarray
{ An array of name-value pairs of additional user data items. Default empty array.
@type string $name The user-facing name of an item name-value pair,e.g. 'IP Address'.
@type string $value The user-facing value of an item data pair, e.g. '50.60.70.0'.
}
  • $namestring

    The user-facing name of an item name-value pair,e.g. 'IP Address'.
  • $valuestring

    The user-facing value of an item data pair, e.g. '50.60.70.0'.
$userWP_User
The user whose data is being exported.
$reserved_namesstring[]
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.

Where this hook fires · 1

  • wp-includes/user.php:4035wp_user_personal_data_exporter()

Source code

	 *     @type string $value The user-facing value of an item data pair, e.g. '50.60.70.0'.	 * }	 * @param WP_User  $user           The user whose data is being exported.	 * @param string[] $reserved_names 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.	 */	$_extra_data = apply_filters( 'wp_privacy_additional_user_profile_data', array(), $user, $reserved_names ); 	if ( is_array( $_extra_data ) && ! empty( $_extra_data ) ) {		// Remove items that use reserved names.		$extra_data = array_filter(			$_extra_data,			static function ( $item ) use ( $reserved_names ) {

Changelog

Introduced in 5.4.0. Unchanged from 6.7.7 through 7.1.0.

  1. 6.7.7
  2. 6.8.8
  3. 6.9.7
  4. 7.0.4
  5. 7.1.0

Signature, return type and hooks compared across 5 parsed releases.

About this page

Parsed data
Generated from the wordpress-develop 6.8.8 tag, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
Corrections
Something wrong on this page? Report it and it gets fixed in the next regeneration.