MyBB Community Forums

Full Version: Last poster in the announcements
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
hi to everybody,

is there a way to show the last poster's name in the announcements?
i'm trying to modify the "portal_announcement_numcomments" template, but i don't know what code i have to insert.

can you help me, please?
thanks in advance! Smile
try using {$lastpost_profilelink}
i tried with that one, but it didn't work.

i succeded in showing just the name of the last poster, but i wish it were a link to his profile and not just a simple text

this is what i added to the template:
<a href="{$mybb->settings['bburl']}/{$announcement['lastpost_profilelink']}">{$announcement['lastposter']}</a>

the problem is that {$announcement['lastpost_profilelink']} doesn't work. it doesn't lead me to the last poster's profile.
no one can help...? ._.
Replace your portal_announcement_numcomments template with this:

- <a href="{$mybb->settings['bburl']}/{$announcement['threadlink']}">{$lang->replies}</a> ({$announcement['replies']}) - Last Post by: {$lastposterlink}
no, it doesn't work ._.
it shows nothing after "last post by"
I just tried this and it works. Are you sure you copied and pasted the code correctly?
i did.
you can see it yourself: http://www.royalgame.org/index.php
(ok it's italian, but if you search "last post by", you'll easily find the changes you suggested me)

ps:
risposte -> replies
Sorry, I was mistaken. That did not work at all. But this should work just fine:

- <a href="{$mybb->settings['bburl']}/{$announcement['threadlink']}">{$lang->replies}</a> ({$announcement['replies']}) - Last Post by: <a href="member.php?action=profile&uid={$announcement['lastposteruid']}">{$announcement['lastposter']}</a>
wuah! thank you! Smile
now it works Smile

thank you so much ^^
Pages: 1 2