Users

Here, you will learn on how to grab and manipulate user's data

Retrieving User's Name

It is possible that the site admin configures EasySocial to use username instead of real name as the display name or vice versa. Your extension should always rely on getName to retrieve the user's name.

Example:

require_once(JPATH_ADMINISTRATOR . '/components/com_easysocial/includes/easysocial.php');
$my = ES::user();
echo $my->getName();
// Shorter way of writing it
echo ES::user()->getName();
// Getting another person's name
echo ES::user($id)->getName();

Supplied Arguments

public function getName($useFormat = '')