XF 1.2 Last poster {xen:

tommydamic68

Well-known member
I am trying to find the code for the last poster in a thread or message - see image where the arrow is pointing.

ooooo.webp

This doesn't seem to work, am i missing something? {xen:username user="$boardTotals.latestUser" />
 
Look in the node_forum_level_2 template.
What code do I use?

Code:
<xen:hook name="node_forum_level_2_before_lastpost" params="{xen:array 'forum={$forum}'}" />

        <div class="nodeLastPost secondaryContent">
            <xen:if is="{$forum.privateInfo}">
                <span class="noMessages muted">({xen:phrase private})</span>
            <xen:elseif is="{$forum.lastPost.date}" />
                <span class="lastThreadTitle"><span>{xen:phrase latest}:</span> <a href="{xen:link posts, $forum.lastPost}" title="{$forum.lastPost.title}">{$forum.lastPost.title}</a></span>
                <span class="lastThreadMeta">
                    <span class="lastThreadUser"><xen:if is="{xen:helper isIgnored, $forum.last_post_user_id}">{xen:phrase ignored_member}<xen:else /><xen:username user="$forum.lastPost" /></xen:if>,</span>
                    <xen:datetime time="$forum.lastPost.date" class="muted lastThreadDate" data-latest="{xen:phrase latest}: " />
                </span>
            <xen:else />

It needs to be added here:

Code:
div class="meta">
            {xen:phrase post_by}: <xen:username user="$post" />, <xen:datetime time="{$post.post_date}" />, {xen:phrase x_replies, 'count={xen:number $thread.reply_count}'}, {xen:phrase views} {$thread.view_count},
            {xen:phrase in_forum}: <a href="{xen:link forums, $forum}">{$forum.title}</a>
        </div>
    </div>
 
no, just made a bunch of goobly code on site, with just {xen:helper 'dump', $forum} by itself and like this:

{xen:helper 'dump', $forum}: <xen:username user="$forum.lastPost" />
 
Back
Top Bottom