Quick Q. Is there a setting to switch the username to the logged in users fullname at the top right of revo?
Thanks
I don't know of one. I think you'd have to change the Manager template or use a plugin attached to OnManagerPageBeforeRender. Changing the Manager template would be easier, but you'd have to find it, and your change might be overwritten when you upgrade MODX unless you create your own Manage template.
-
☆ A M B ☆
- 24,524 Posts
Whenever I change the Manager template or styling, I duplicate the existing default template, then edit my duplicate and tell MODX to use my duplicate. That way nothing gets overwritten on updates.
-
☆ A M B ☆
- 24,524 Posts
First you need to edit the controller file, /manger/controllers/<theme-name>/header.php around line 93:
$userprofile = $modx->user->getOne('Profile');
$this->setPlaceholder('fullname',$userprofile->get('fullname'));
The template to edit is in /manager/templates/<theme-name>/header.tpl, line 52:
{if $canChangeProfile}<a class="modx-user-profile" href="?a={$profileAction}">{$fullname}</a>{else}<span class="modx-user-profile">{$fullname}</span>{/if}
Quote from: Steeve at Jan 12, 2016, 03:00 AM
Hi,
There is another (simplest) way to do this :
Just change manager_use_fullname to yes in the system setting.
Et voilà ! ;-)
Yes, that would definitely be easier.
-
☆ A M B ☆
- 24,524 Posts
Only available since August of 2015 with the 2.4.0 release.
https://github.com/modxcms/revolution/pull/12527
MODX Revolution 2.4.0-rc1 (August 12, 2015)
...
- New setting manager_use_fullname will show the fullname of the logged in user, instead of the username [#12527]
...