user_is_logged_in
function user_is_logged_in
user_is_logged_in()
Determines if the current user is logged in.
Return value
bool TRUE if the user is logged in, FALSE if the user is anonymous.
File
- modules/user/user.module, line 1574
- Enables the user registration and login system.
Code
function user_is_logged_in() { return (bool) $GLOBALS['user']->uid; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!user!user.module/function/user_is_logged_in/7.x