XF 1.5 Button new thread is missing (forum view)

Betclever

Active member
#1
Hi,

The button "new thread" is missing on the forum view template.
I added this code but it doesn't redirect correctly... What's wrong please?

HTML:
<xf:if is="$forum.canCreateThread()">
    <xf:pageaction><a href="{{ link('forums/create-thread', $forum) }}" class="button button--cta {{ button_icon('new') }}">Post thread</a></xf:pageaction>
</xf:if>
TYVM.
 

Betclever

Active member
#3
That's not valid XF1 template code.

Revert the template and that should restore it.
In fact, I found this code on the web but what I have actually this one:

Code:
<xen:if is="{$canPostThread}">
    <xen:set var="$newDiscussionButton"><a href="{xen:link 'forums/create-thread', $forum}" class="callToAction"><span>{xen:phrase post_new_thread}</span></a></xen:set>
    <xen:if is="!{$renderedNodes}">
        <xen:topctrl>{xen:raw $newDiscussionButton}</xen:topctrl>
    </xen:if>
</xen:if>
 
Last edited:
Top