delete_user_form
Fires at the end of the delete users form prior to the confirm button.
Usage
add_action( 'delete_user_form', 'wp_kama_delete_user_form_action', 10, 2 ); /** * Function for `delete_user_form` action-hook. * * @param WP_User $current_user WP_User object for the current user. * @param int[] $user_ids Array of IDs for users being deleted. * * @return void */ function wp_kama_delete_user_form_action( $current_user, $user_ids ){ // action... }
- $current_user(WP_User)
- WP_User object for the current user.
- $user_ids(int[])
- Array of IDs for users being deleted.
Changelog
Since 4.0.0 | Introduced. |
Since 4.5.0 | The $user_ids parameter was added. |
Where the hook is called
In file: /wp-admin/users.php
wp-admin/users.php 441
do_action( 'delete_user_form', $current_user, $user_ids );
wp-admin/includes/ms.php 987
do_action( 'delete_user_form', $current_user, $allusers );