Jump to content

Calling groupName in a formatted version.


Zachary H

Recommended Posts

Hello,

I am modifying the template for the Staff Directory, and I am attempting to replace the rank/title with the group name the user is assigned to.

I have replaced the following code:

<p class='ipsType_reset ipsType_normal ipsType_light'>
				{{if \IPS\Member::loggedIn()->language()->checkKeyExists( "core_staff_directory_title_" . $user->id )}}
					{lang="core_staff_directory_title_{$user->id}" escape="true"}
				{{else}}
					{{if $user->member()->member_title}}
						{$user->member()->member_title}
					{{elseif $user->member()->rank['title']}}
						{$user->member()->rank['title']}
					{{endif}}
				{{endif}}
			</p>

With:

<p class='ipsType_reset ipsType_normal ipsType_light'>
				{$user->member()->groupName}
</p>

However, upon making these changes, it will display the group name with the html formatting for the entire group such as "<span style='color:#000000'>Group Name</span>".

Can anyone provide me with some guidance? I'm brand-new to Invision Power Board.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...