Retrieve the current user object.
Signature
wp_get_current_user()
Return
(WP_User) Current user WP_User object
Source
function wp_get_current_user() {
global $current_user;
get_currentuserinfo();
return $current_user;
}
WP Trac GitHub Bitbucket
Link here
-
URL
http://queryposts.com/function/wp_get_current_user/ -
HTML
<a href='http://queryposts.com/function/wp_get_current_user/'>wp_get_current_user()</a> -
Markdown
[wp_get_current_user()](http://queryposts.com/function/wp_get_current_user/) -
BBCode
[url=http://queryposts.com/function/wp_get_current_user/]wp_get_current_user()[/url]