This documentation describes unreleased changes on the main branch.

wp_user_url()

Twig function of the framework; its result is escaped like any value.

{{ wp_user_url(id) }}

The URL of the author archive of a user, as returned by get_author_posts_url(). Returns '' if the ID is null or the user does not exist.

<a href="{{ wp_user_url(attrs.author) }}">{{ wp_user_name(attrs.author) }}</a>
ParameterTypeDefaultDescription
idint|nullrequiredID of the user.

Returns string