XF 2.0 Error replacing template

canina

Active member
I am trying to replace the prefix_input template

I chose the content

Code:
<xf:mustache name="#title">
    <h3 class="menu-header">{{ mustache('title') }}</h3>
</xf:mustache>

I replaced it with content

Code:
<xf:if is="{$thread.node_id} == 141">

    <xf:mustache name="#title">
        <h3 class="menu-header">{{ mustache('title') }}</h3>
    </xf:mustache>
<xf:else />
    $0
</xf:if>

But it's not working. Why?

Thank you
 
If I'm not blind your if clause does nothing. In both cases it will print out
HTML:
<xf:mustache name="#title">
    <h3 class="menu-header">{{ mustache('title') }}</h3>
</xf:mustache>
I assume you only want to display that part in node 141. So just kill
<xf:else /> $0
 
If it is not node 141 then there should be another result.
For example:

Code:
<xf:if is="{$thread.node_id} == 141">

    <xf:mustache name="#title">
        <h3 class="menu-header">business name</h3>
    </xf:mustache>
<xf:else />
    $0
</xf:if>

And that does not work either

Thank you
 
Back
Top Bottom