I could not find the code.post_macros
<article class="message-body js-selectToQuote">
<xf:ad position="post_above_content" arg-post="{$post}" />
{{ bb_code($post.message, 'post', $post) }}
<div class="js-selectToQuoteEnd"> </div>
<xf:ad position="post_below_content" arg-post="{$post}" />
</article>
<article class="message-body js-selectToQuote">
<xf:ad position="post_above_content" arg-post="{$post}" />
<xf:if is="!$xf.visitor.user_id">
<xf:set var="$snippetPost" value="{{ snippet($post.message, 300) }}" />
{{ bb_code($snippetPost, 'post', $post) }}
<xf:if is="$snippetPost != $post.message">
<div class="blockMessage blockMessage--important blockMessage--iconic">
Please login to view full content
</div>
</xf:if>
<xf:else/>
{{ bb_code($post.message, 'post', $post) }}
</xf:if>
<div class="js-selectToQuoteEnd"> </div>
<xf:ad position="post_below_content" arg-post="{$post}" />
</article>
<article class="message-body js-selectToQuote">
<xf:ad position="post_above_content" arg-post="{$post}" />
<xf:if is="!$xf.visitor.user_id">
<xf:set var="$snippetPost" value="{{ snippet($post.message, 300) }}" />
{{ bb_code($snippetPost, 'post', $post) }}
<div class="blockMessage blockMessage--important blockMessage--iconic">
Please login to view full content
</div>
<xf:else/>
{{ bb_code($post.message, 'post', $post) }}
</xf:if>
<div class="js-selectToQuoteEnd"> </div>
<xf:ad position="post_below_content" arg-post="{$post}" />
</article>
<div class="block-body js-replyNewMessageContainer">
<xf:foreach loop="$posts" value="$post">
<xf:if is="$post.message_state == 'deleted'">
<xf:macro template="post_macros" name="post_deleted"
arg-post="{$post}"
arg-thread="{$thread}" />
<xf:else />
<xf:macro template="post_macros" name="post"
arg-post="{$post}"
arg-thread="{$thread}" />
</xf:if>
</xf:foreach>
</div>
</div>
<div class="block-body js-replyNewMessageContainer">
<xf:foreach loop="$posts" value="$post">
<xf:if is="$post.message_state == 'deleted'">
<xf:macro template="post_macros" name="post_deleted"
arg-post="{$post}"
arg-thread="{$thread}" />
<xf:else />
<xf:if is="!$xf.visitor.user_id AND $post.isFirstPost() OR $xf.visitor.user_id">
<xf:macro template="post_macros" name="post"
arg-post="{$post}"
arg-thread="{$thread}" />
</xf:if>
</xf:if>
</xf:foreach>
</div>
</div>
<xf:pagenav
page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}"
link="threads" data="{$thread}"
wrapperclass="block-outer-main" />
<xf:if is="$xf.visitor.user_id">
<xf:pagenav
page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}"
link="threads" data="{$thread}"
wrapperclass="block-outer-main" />
</xf:if>
<xf:pagenav
page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}"
link="threads" data="{$thread}"
wrapperclass="block-outer-main" />
<xf:if is="$xf.visitor.user_id">
<xf:pagenav
page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}"
link="threads" data="{$thread}"
wrapperclass="block-outer-main" />
</xf:if>
Hello,Ok, now replace with this in post_macros template
In thread_view templateHTML:<article class="message-body js-selectToQuote"> <xf:ad position="post_above_content" arg-post="{$post}" /> <xf:if is="!$xf.visitor.user_id"> <xf:set var="$snippetPost" value="{{ snippet($post.message, 300) }}" /> {{ bb_code($snippetPost, 'post', $post) }} <div class="blockMessage blockMessage--important blockMessage--iconic"> Please login to view full content </div> <xf:else/> {{ bb_code($post.message, 'post', $post) }} </xf:if> <div class="js-selectToQuoteEnd"> </div> <xf:ad position="post_below_content" arg-post="{$post}" /> </article>
find
Replace with thisHTML:<div class="block-body js-replyNewMessageContainer"> <xf:foreach loop="$posts" value="$post"> <xf:if is="$post.message_state == 'deleted'"> <xf:macro template="post_macros" name="post_deleted" arg-post="{$post}" arg-thread="{$thread}" /> <xf:else /> <xf:macro template="post_macros" name="post" arg-post="{$post}" arg-thread="{$thread}" /> </xf:if> </xf:foreach> </div> </div>
HTML:<div class="block-body js-replyNewMessageContainer"> <xf:foreach loop="$posts" value="$post"> <xf:if is="$post.message_state == 'deleted'"> <xf:macro template="post_macros" name="post_deleted" arg-post="{$post}" arg-thread="{$thread}" /> <xf:else /> <xf:if is="!$xf.visitor.user_id AND $post.isFirstPost() OR $xf.visitor.user_id"> <xf:macro template="post_macros" name="post" arg-post="{$post}" arg-thread="{$thread}" /> </xf:if> </xf:if> </xf:foreach> </div> </div>
find
ReplaceHTML:<xf:pagenav page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}" link="threads" data="{$thread}" wrapperclass="block-outer-main" />
findHTML:<xf:if is="$xf.visitor.user_id"> <xf:pagenav page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}" link="threads" data="{$thread}" wrapperclass="block-outer-main" /> </xf:if>
replaceHTML:<xf:pagenav page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}" link="threads" data="{$thread}" wrapperclass="block-outer-main" />
HTML:<xf:if is="$xf.visitor.user_id"> <xf:pagenav page="{$page}" perpage="{$perPage}" total="{{ $thread.reply_count + 1 }}" link="threads" data="{$thread}" wrapperclass="block-outer-main" /> </xf:if>
SureHello,
Can I have your permission to make an add-on with this tutorial ? Of course with the credits in the thread/addon.json !
Regards, SyTry
Hi!Hello,
Can I have your permission to make an add-on with this tutorial ? Of course with the credits in the thread/addon.json !
Regards, SyTry
Hello,Hi!
Did you make it ? Thanks .
We use essential cookies to make this site work, and optional cookies to enhance your experience.