XF 1.2 Hide Reply Button for First Post in Specific Forum

QenTox

Well-known member
This add-on can hide the reply button for first post. Can someone please tell me how to modify this if I want to hide reply button only for certain forum?
 
Thanks, but I am not really good with this, tried that few times, but I always get this error: The following templates contained errors and were not saved: post: 1) Line 51: Template syntax error.

Could you please post here the exact place, where should I place that .node22 code?
 
Thanks, no error this time but for some reason still in all forums is the reply button hidden in first post. Tried CTRL + F5, but still no change.
 
Actually the code you provided hides the reply button for all posts in all forums except the specified node, where reply button is in all posts except the first post.
 
Like this?

Code:
<xen:if is="{$forum.node_id}==22">
  <xen:if is="{$post.position}!=0">
    <xen:if is="{$canReply}">
      <a href="{xen:link threads/reply, $thread, 'quote={$post.post_id}'}" data-postUrl="{xen:link posts/quote, $post}" class="ReplyQuote item control reply" title="{xen:phrase reply_quoting_this_message}"><span></span>{xen:phrase reply}</a>
    </xen:if>
  </xen:if>
</xen:if>

It seems like it does the same as the code before.
 
Code:
<xen:if is="{$forum.node_id}==22">
<xen:else />
  <xen:if is="{$post.position}!=0">
    <xen:if is="{$canReply}">
      <a href="{xen:link threads/reply, $thread, 'quote={$post.post_id}'}" data-postUrl="{xen:link posts/quote, $post}" class="ReplyQuote item control reply" title="{xen:phrase reply_quoting_this_message}"><span></span>{xen:phrase reply}</a>
    </xen:if>
  </xen:if>
</xen:if>

Not sure if I did it right, but now I have no reply at all in specified forum and in all other forums there is reply button for all posts except the first.
 
Top Bottom