WP_Privacy_Data_Removal_Requests_List_Table::column_next_steps( WP_User_Request $item )
- Since
- 4.9.6
- Source
wp-admin/includes/class-wp-privacy-data-removal-requests-list-table.php:117
Outputs the Next steps column.
Parameters
$itemWP_User_Request- Item being shown.
Hooks fired · 1
One hook fires while WP_Privacy_Data_Removal_Requests_List_Table::column_next_steps() runs, in this order:
- apply_filters( wp_privacy_personal_data_erasers )filterline 126 (+9 into the body)
Filters the array of personal data eraser callbacks.
Uses · 11
- esc_html_e()Displays translated text that has been escaped for safe use in HTML output.
- apply_filters()Calls the callback functions that have been added to a filter hook.
- wp_create_nonce()Creates a cryptographic token tied to a specific action, user, user session, and window of time.
- esc_attr()Escaping for HTML attributes.
- _e()Displays translated text.
- __()Retrieves the translation of $text.
- esc_url()Checks and cleans a URL.
- wp_nonce_url()Retrieves URL with nonce added to URL query.
- add_query_arg()Retrieves a modified URL query string.
- admin_url()Retrieves the URL to the admin area for the current site.
- esc_html__()Retrieves the translation of $text and escapes it for safe use in HTML output.
Source
public function column_next_steps( $item ) { $status = $item->status; switch ( $status ) { case 'request-pending': esc_html_e( 'Waiting for confirmation' ); break; case 'request-confirmed': /** This filter is documented in wp-admin/includes/ajax-actions.php */ $erasers = apply_filters( 'wp_privacy_personal_data_erasers', array() ); $erasers_count = count( $erasers ); $request_id = $item->ID; $nonce = wp_create_nonce( 'wp-privacy-erase-personal-data-' . $request_id ); echo '<div class="remove-personal-data" ' . 'data-force-erase="1" ' . 'data-erasers-count="' . esc_attr( $erasers_count ) . '" ' . 'data-request-id="' . esc_attr( $request_id ) . '" ' . 'data-nonce="' . esc_attr( $nonce ) . '">'; ?> <span class="remove-personal-data-idle"><button type="button" class="button-link remove-personal-data-handle"><?php _e( 'Erase personal data' ); ?></button></span> <span class="remove-personal-data-processing hidden"><?php _e( 'Erasing data...' ); ?> <span class="erasure-progress"></span></span> <span class="remove-personal-data-success success-message hidden" ><?php _e( 'Erasure completed.' ); ?></span> <span class="remove-personal-data-failed hidden"><?php _e( 'Data erasure has failed.' ); ?> <button type="button" class="button-link remove-personal-data-handle"><?php _e( 'Retry' ); ?></button></span> <?php echo '</div>'; break; case 'request-failed': echo '<button type="submit" class="button-link" name="privacy_action_email_retry[' . $item->ID . ']" id="privacy_action_email_retry[' . $item->ID . ']">' . __( 'Retry' ) . '</button>'; break; case 'request-completed': echo '<a href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'delete', 'request_id' => array( $item->ID ), ), admin_url( 'erase-personal-data.php' ) ), 'bulk-privacy_requests' ) ) . '">' . esc_html__( 'Remove request' ) . '</a>'; break; } }History
Introduced in 4.9.6. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
About this page
- Parsed data
- Generated from the wordpress-develop 7.1.0 tag, from
src/wp-admin/includes/class-wp-privacy-data-removal-requests-list-table.php, 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.