Member details¶
{exp:visitor:details}
Parses the member fields of the Zoo Visitor channel. When no parameter is provided, the current logged in member details are parsed. When using member_id, member_entry_id or username parameter, the specified member details based on the parameter are parsed.
Member details tag parameters¶
member_id¶
id of the member where you want to get field details from, when this parameter and member_entry_id is not specified, the details are fetched of the current logged in user.
member_entry_id¶
id of the member channel entry where you want to get field details from.
username¶
username of the member where you want to get field details from.
url_title¶
get member details based on the url_title.
Example: In the Visitor settings page, set title override to {member_firstname} {member_lastname}, this will make sure the url title is not using the username or email, but instead use the first-and lastname of the member. Let’s say you are on page /members/profile/tom-selleck and want to get the details of this member.
- {exp:visitor:details url_title=”{segment_3}”}
- {visitor:member_firstname} {visitor:member_lastname}
{/exp:visitor:details}
Member details tag examples¶
Member details based on their name as url segment¶
In this example, we are showing firstname/lastname of the current logged in user and displaying fields member_lastname/member_firstname from the Zoo Visitor channel.
{exp:visitor:details}
{visitor:member_firstname} {visitor:member_lastname}
{/exp:visitor:details}
Show member details of the author of a comment¶
{exp:comment:entries channel="news"}
{exp:visitor:details member_id="{author_id}"}
{comment} by {visitor:member_firstname} {visitor:member_lastname}
{/exp:visitor:details}
{/exp:comment:entries}