On this page
WP_User::get( string $key ): mixed
Retrieves the value of a property or meta key.
Description
Retrieves from the users and usermeta table.
Parameters
$keystring Required-
Property
Return
mixed
Source
File: wp-includes/class-wp-user.php. View all references
public function get( $key ) {
return $this->__get( $key );
}
Related
Uses
| Uses | Description |
|---|---|
| WP_User::__get() wp-includes/class-wp-user.php | Magic method for accessing custom fields. |
Changelog
| Version | Description |
|---|---|
| 3.3.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_user/get