XF 2.2 How to swap avatar and user title?

Dkf

Active member
Now:
[Username]
[Avatar]
[User title]

I want:
[Username]
[User title]
[Avatar]

Thank You
 
Solution
Try, in message_macros template, replace this

HTML:
<div class="message-avatar {{ ($xf.options.showMessageOnlineStatus && $user && $user.isOnline()) ? 'message-avatar--online' : '' }}">
    <div class="message-avatar-wrapper">
        <xf:avatar user="$user" size="m" defaultname="{$fallbackName}" itemprop="image" />
        <xf:if is="$xf.options.showMessageOnlineStatus && $user && $user.isOnline()">
            <span class="message-avatar-online" tabindex="0" data-xf-init="tooltip" data-trigger="auto" title="{{ phrase('online_now')|for_attr }}"></span>
        </xf:if>
    </div>
</div>
<div class="message-userDetails">
    <h4 class="message-name"><xf:username user="$user" rich="true" defaultname="{$fallbackName}" itemprop="name"...
Try, in message_macros template, replace this

HTML:
<div class="message-avatar {{ ($xf.options.showMessageOnlineStatus && $user && $user.isOnline()) ? 'message-avatar--online' : '' }}">
    <div class="message-avatar-wrapper">
        <xf:avatar user="$user" size="m" defaultname="{$fallbackName}" itemprop="image" />
        <xf:if is="$xf.options.showMessageOnlineStatus && $user && $user.isOnline()">
            <span class="message-avatar-online" tabindex="0" data-xf-init="tooltip" data-trigger="auto" title="{{ phrase('online_now')|for_attr }}"></span>
        </xf:if>
    </div>
</div>
<div class="message-userDetails">
    <h4 class="message-name"><xf:username user="$user" rich="true" defaultname="{$fallbackName}" itemprop="name" /></h4>
    <xf:usertitle user="$user" tag="h5" class="message-userTitle" banner="true" itemprop="jobTitle" />
    <xf:userbanners user="$user" tag="div" class="message-userBanner" itemprop="jobTitle" />
</div>

by this

HTML:
<div class="message-userDetails">
    <h4 class="message-name"><xf:username user="$user" rich="true" defaultname="{$fallbackName}" itemprop="name" /></h4>
</div>
<div class="message-avatar {{ ($xf.options.showMessageOnlineStatus && $user && $user.isOnline()) ? 'message-avatar--online' : '' }}">
    <div class="message-avatar-wrapper">
        <xf:avatar user="$user" size="m" defaultname="{$fallbackName}" itemprop="image" />
        <xf:if is="$xf.options.showMessageOnlineStatus && $user && $user.isOnline()">
            <span class="message-avatar-online" tabindex="0" data-xf-init="tooltip" data-trigger="auto" title="{{ phrase('online_now')|for_attr }}"></span>
        </xf:if>
    </div>
</div>
<div class="message-userDetails">
    <xf:usertitle user="$user" tag="h5" class="message-userTitle" banner="true" itemprop="jobTitle" />
    <xf:userbanners user="$user" tag="div" class="message-userBanner" itemprop="jobTitle" />
</div>
 
Solution
Back
Top Bottom