Adam H
08-14-2011, 09:45 PM
Hi everyone, Im making a mobile theme for one of my forums and i cant seem to get the threads to use the "first unread post" function. So when a user clicks a thread instead of taking them to the first post of the thread it takes them to the first unread post in that thread.
This is the code im using in the thread bit template , as you can see ive added the Last post icon too which is how i want it .
<li>
<a class="title<vb:if condition="$show['gotonewpost']"> threadtitle_unread</vb:if>" href="{vb:link thread, {vb:raw thread}, {vb:raw pageinfo}, 'threadid', 'threadtitle'}" id="thread_title_{vb:raw thread.realthreadid}">{vb:raw thread.threadtitle}</a>
<a href="{vb:link thread, {vb:raw thread}, {vb:raw pageinfo_lastpost}, 'threadid', 'threadtitle'}#post{vb:raw pageinfo_lastpost.p}" class="lastpostdate understate" title="{vb:rawphrase go_to_last_post}"><img src="{vb:stylevar imgdir_button}/lastpost-{vb:stylevar right}.png" alt="{vb:rawphrase go_to_last_post}" /></a>
<div class="smallfontlight">{vb:rawphrase replies}: {vb:raw thread.replycount} | {vb:rawphrase views}: {vb:raw thread.views}</div>
</li>
This is the code im using in the thread bit template , as you can see ive added the Last post icon too which is how i want it .
<li>
<a class="title<vb:if condition="$show['gotonewpost']"> threadtitle_unread</vb:if>" href="{vb:link thread, {vb:raw thread}, {vb:raw pageinfo}, 'threadid', 'threadtitle'}" id="thread_title_{vb:raw thread.realthreadid}">{vb:raw thread.threadtitle}</a>
<a href="{vb:link thread, {vb:raw thread}, {vb:raw pageinfo_lastpost}, 'threadid', 'threadtitle'}#post{vb:raw pageinfo_lastpost.p}" class="lastpostdate understate" title="{vb:rawphrase go_to_last_post}"><img src="{vb:stylevar imgdir_button}/lastpost-{vb:stylevar right}.png" alt="{vb:rawphrase go_to_last_post}" /></a>
<div class="smallfontlight">{vb:rawphrase replies}: {vb:raw thread.replycount} | {vb:rawphrase views}: {vb:raw thread.views}</div>
</li>