How to display a public profile page for registered users with custom slug?


I have a website where users can register, login and their edit profile, they can comment but not post.

What I am looking for is a way to display a user profile page (where I display the gravatar and the info about the user) clicking on the username.
The url must be something like “”.

I know about author.php, but I don’t know how to link even if the user has no posts and is not an author.


I managed to solve it. Instead of linking using <?php the_author_posts_link(); ?> I did an href linking to<?php echo $user_info->display_name; ?>

To rename the slug I installed the Edit author slug plugin, it makes the author slug editable under Settings > permalinks.

To customize the user profile, just edit authors.php as you like.

Andycap 2 years 2020-12-18T16:10:30-05:00 0 Answers 6 views 0

Leave an answer