On the search page I permit the user to click a around the authors title to see all posts with that author. Im attempting to produce the connect to the authors page however i keep getting 404’s. Nevertheless the admin user works. I've checked the consumer types and they're set authors (Admin is administrator).

Code Example

get_author_posts_url(get_the_author_ID()); 

Result

This returns "/author/tester/" which looks correct because the admin one "/author/admin/" works. However clicking the hyperlink would go to 404.

Notes

  • This code is performed inside a Wordpress loop.
  • User type is Author.
  • Ideally I must make use of the customers nickname/display title not actual.

Try :

get_author_posts_url( $author->ID )

Also since you are utilizing it inside the loop, try with no ID :

get_author_posts_url()

A far more complex function shows up at :

http://www.codesphp.com/cms/wordpress/get-wordpress-author-page-url-with-user-id.html