
如何修复MAMP本地环境phpMyAdmin不工作错误
is_avatar_comment_type ( $comment_type )
is_avatar_comment_type: 这个函数检查一个给定的评论类型是否是头像评论类型。头像评论类型是由WordPress自动生成的评论,以显示作者的头像。如果给定的评论类型是一个头像评论类型,它返回真,否则返回假。
检查该评论类型是否允许检索头像。
function is_avatar_comment_type( $comment_type ) { /** * Filters the list of allowed comment types for retrieving avatars. * * @since 3.0.0 * * @param array $types An array of content types. Default only contains 'comment'. */ $allowed_comment_types = apply_filters( 'get_avatar_comment_types', array( 'comment' ) ); return in_array( $comment_type, (array) $allowed_comment_types, true ); }