In this way, we can get the relevant information of the Author. if we want to add the author's introduction to our website, we can use this method, such as the author information on linzl.com.
Note: If you want to display user information but do not want to display it (for example, in the php method), use the get_the_author_meta () method.
Usage:
Parameter description:
$ Field (string) field name of the user information to be displayed (which can be found in the database ). Commonly used:
User_login (user login name)
User_pass (user logon password)
User_nicename (user nickname)
User_email (user email address)
User_url (user website address)
User_registered (user registration time)
User_status (user status)
Display_name (name displayed by the author)
Nickname (nickname of the author)
First_name (author name)
Last_name (author's surname)
Description)
User_level (user level)
User_firstname (username)
User_lastname (user name)
User_description (user description)
ID (user ID value)
Example:
// Obtain the author's email address
// Obtain the nickname of the Author
In this way, we can get the relevant information of the Author. if we want to add the author's introduction to our website, we can use this method, such as the author information on linzl.com.
It is important to note whether it is in the article loop. if not, you need to add the author's ID value. You can find it in the wp_users table of the database.