Loading an User Object with User Name or User ID in Joomla

You can load a specific user object with just the user name or user ID when using the getUser() method.


$user = JFactory::getUser('username');
$user = JFactory::getUser(55);

Leave a comment

1 Comments.

  1. Thanks a lot for this. it saved hours of work for me

Leave a Reply


[ Ctrl + Enter ]