функция
Устаревший since 1.5.0
user_can_delete_post_comments()
Устаревшее.
Помечено устаревшим с версии 2.0.0.
Проверено на WordPress 6.9, обновлено Источник: WordPress Developer Resources.
Сигнатура
user_can_delete_post_comments( int $user_id, int $post_id, int $blog_id = 1 ): bool
Описание
См. alsocurrent_user_can()
Оригинал (английский)
Параметры
$user_id
int
обязательный
$post_id
int
обязательный
$blog_id
int
необязательный
= 1
Не используется.
Возвращаемое значение
bool
Исходный код
wp-includes/deprecated.php:350
function user_can_delete_post_comments($user_id, $post_id, $blog_id = 1) {
_deprecated_function( __FUNCTION__, '2.0.0', 'current_user_can()' );
// Right now if one can edit comments, one can delete comments.
return user_can_edit_post_comments($user_id, $post_id, $blog_id);
}
История изменений
| Версия | Описание |
|---|---|
| 2.0.0 | Deprecated. Use current_user_can() |
| 1.5.0 | Introduced. |

