List WordPress User Information

 In All, Users

Here is an easy way to display flexible lists of your blog’s registered users’ information. In this example, we will list the first and last name of each user registered in the database:

List WordPress User Information

 

The following variables may be used to display different types of user information and also to specify the sort order of the output list:

  1. ID — User ID number
  2. user_login — User Login name
  3. user_nicename — nice version of login name
  4. user_email — User Email Address
  5. user_url — User Website URL
  6. user_registered — User Registration date

To display any of these different types of user information, call it with $user->name_of_the_column anywhere within the function’s foreach() loop. To change the display order of the output, use any of the above as the value of the $szSort variable in the first line of the function. Note that strtolower and ucwords are used to ensure proper capitalization of the user names.

Security must have – Prevent Enumeration of Usernames In Nginx. Please visit Nuno Sarmento @  https://www.nuno-sarmento.com for the code snippet.

Recommended Posts

Leave a Comment

Contact Us

We're not around right now. But you can send us an email and we'll get back to you, asap.

Start typing and press Enter to search

Display Last Modified Time and Date for PostsDisplay Last Modified Time and Date for Posts