Filter hook 'wp_privacy_personal_data_export_page'

in WP Core File wp-admin/includes/ajax-actions.php at line 5101

View Source

wp_privacy_personal_data_export_page

Filter Hook
Description
Filters a page of personal data exporter data. Used to build the export report. Allows the export response to be consumed by destinations in addition to Ajax.

Hook Information

File Location wp-admin/includes/ajax-actions.php View on GitHub
Hook Type Filter
Line Number 5101

Hook Parameters

Type Name Description
array $response The personal data for the given exporter and page number.
int $exporter_index The index of the exporter that provided this data.
string $email_address The email address associated with this personal data.
int $page The page number for this response.
int $request_id The privacy request post ID associated with this request.
bool $send_as_email Whether the final results of the export should be emailed to the user.
string $exporter_key The key (slug) of the exporter that provided this data.

Usage Examples

Basic Usage
<?php
// Hook into wp_privacy_personal_data_export_page
add_filter('wp_privacy_personal_data_export_page', 'my_custom_filter', 10, 7);

function my_custom_filter($response, $exporter_index, $email_address, $page, $request_id, $send_as_email, $exporter_key) {
    // Your custom filtering logic here
    return $response;
}

Source Code Context

wp-admin/includes/ajax-actions.php:5101 - How this hook is used in WordPress core
<?php
5096  	 * @param int    $page            The page number for this response.
5097  	 * @param int    $request_id      The privacy request post ID associated with this request.
5098  	 * @param bool   $send_as_email   Whether the final results of the export should be emailed to the user.
5099  	 * @param string $exporter_key    The key (slug) of the exporter that provided this data.
5100  	 */
5101  	$response = apply_filters( 'wp_privacy_personal_data_export_page', $response, $exporter_index, $email_address, $page, $request_id, $send_as_email, $exporter_key );
5102  
5103  	if ( is_wp_error( $response ) ) {
5104  		wp_send_json_error( $response );
5105  	}
5106  

PHP Documentation

<?php
/**
	 * Filters a page of personal data exporter data. Used to build the export report.
	 *
	 * Allows the export response to be consumed by destinations in addition to Ajax.
	 *
	 * @since 4.9.6
	 *
	 * @param array  $response        The personal data for the given exporter and page number.
	 * @param int    $exporter_index  The index of the exporter that provided this data.
	 * @param string $email_address   The email address associated with this personal data.
	 * @param int    $page            The page number for this response.
	 * @param int    $request_id      The privacy request post ID associated with this request.
	 * @param bool   $send_as_email   Whether the final results of the export should be emailed to the user.
	 * @param string $exporter_key    The key (slug) of the exporter that provided this data.
	 */
Quick Info
  • Hook Type: Filter
  • Parameters: 7
  • File: wp-admin/includes/ajax-actions.php
Related Hooks

Related hooks will be displayed here in future updates.