user_can_delete_post( int $user_id, int $post_id, int $blog_id = 1 ): bool
- Since
- 1.5.0
- Source
wp-includes/deprecated.php:272
Whether user can delete a post.
Parameters
$user_idint$post_idint$blog_idintoptional- Not UsedDefault:
1
Return
bool
Uses · 2
- _deprecated_function()Marks a function as deprecated and inform when it has been used.
- user_can_edit_post()Whether user can edit a post.
Source
function user_can_delete_post($user_id, $post_id, $blog_id = 1) { _deprecated_function( __FUNCTION__, '2.0.0', 'current_user_can()' ); // Right now if one can edit, one can delete. return user_can_edit_post($user_id, $post_id, $blog_id);}History
Introduced in 1.5.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
2.0.0
Deprecated. Use current_user_can()from the docblock
1.5.0
Introduced.from the docblock
About this page
- Parsed data
- Generated from the wordpress-develop 6.7.7 tag, from
src/wp-includes/deprecated.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.