- b2evolution CMS User Manual
- Developer Reference
- Website Skins/Themes
- Skin Tags / API
- User::get_identity_link()
User::get_identity_link()
Get User identity link, which is a composite of user avatar and login, both point to the specific user profile tab.
Example
<?php
echo $current_User->get_identity_link( array(
'link_text' => 'avatar',
'thumb_size' => 'crop-top-15x15',
'thumb_class' => 'avatar_before_login',
'thumb_zoomable' => false,
'login_mask' => '',
'display_bubbletip' => true,
'nowrap' => true,
) );
?>
Parameters
- link_text : What to display for the author name:
-
'avatar'
or'avatar_login'
: Display avatar + username -
'only_avatar'
: Display only the avatar -
'login'
: Display the username -
'nickname'
: Display the nickname; if empty, fall back to username -
'fistname'
: Display the first name; if empty, fall back to username -
'lastname'
: Display the last name; if empty, fall back to username -
'fullname'
: Display the first and last name; if empty, fall back to username -
'preferredname'
: Display the preferred name: nickname or if empty: fullname, or if empty too: username - thumb_size : Image Size used for the avatar if ‘link_text’ => ‘avatar’.
- thumb_class : Avatar(image) CSS class.
- thumb_zoomable : Do we want the avatar image to be zoomed on click?
- login_mask : Display a mask around the link text; Example: ‘text $login$ text’
- display_bubbletip : Do we want to display a bubbletip on mouseover?
- nowrap : Do we want to use white-space = ‘nowrap’ for the link text?
Return value
A string containing a link to the configured User’s "profile"/identity page.