User Account
Use the {user} Smart Tags to retrieve information about the currently logged-in user. This Smart Tag can return the value of any property from the Joomla User object as long as you know the property's name.
{user.USER_PROPERTY}
Below is a list of this category's most popular Smart Tags.
{user.id}
Returns the ID of the user.
{user.name}
Returns the name of the user.
{user.firstname}
Returns the first name of the user.
{user.lastname}
Returns the last name of the user.
{user.login}
Returns the username of the user.
{user.email}
Returns the email address of the user.
{user.registerDate}
Returns the registration date of the user.
{user.groups}
Returns the IDs of the user groups comma-separated. Eg: 1,2,5.
{user.groupTitles}
Returns the titles of the user groups comma-separated. Eg: Public, Registered
{user.authLevels}
Returns the IDs of the user access levels comma-separated. Eg: 1,2,6
{user.authLevelTitles}
Returns the titles of the user access levels comma-separated. Eg: Public,Registered,Special
Custom Fields
To output a custom field value associated with the currently logged-in user, use:
{user.field.NAME}
Replace NAME with the name (not the label) of your custom field. For instance, if you have a custom field named age:
{user.field.age}
You can access additional properties of a custom field by appending the appropriate property name after the field name.
{user.field.NAME.rawvalue}
{user.field.NAME.id}
For advanced usage, including subforms, field labels and disabling content plugins check the full guide: Using Custom Fields in Smart Tags
Notes
The following rules apply:
- All Smart Tags in this set will return an empty string if the user is not logged in.
- For security purposes, the “password” property can’t be accessed.