I get an error with this template

Okay I did that and it still doesn't show, but I know why.

This is the code you gave me:

Code:
<xen:if is="{$hasPosted}">
      <label><a href="{xen:link search/search, '', 'type=post', 'thread_id={$thread.thread_id}', 'users={$visitor.username}'}">Your Posts</a></label>
<xen:else />
     
</xen:if>

It only shows If I remove the parts of the code you gave me.
 
Okay now it's this.

Code:
 <xen:if is="{$post.user_id} == {$visitor.user_id}">
              <xen:if is="{$hasPosted}">
      <li><a href="{xen:link search/search, '', 'type=post', 'thread_id={$thread.thread_id}', 'users={$visitor.username}'}">Your Posts</a></li>
<xen:else />
     
</xen:if>
            </xen:if>

And it still doesn't show
 
HTML:
        <xen:foreach loop="$posts" value="$post">
            <xen:if is="{$post.user_id} == {$visitor.user_id}">
                <xen:set var="$hasPosted">1</xen:set>
            </xen:if>
        </xen:foreach>

Then you can use:

HTML:
<xen:if is="{$hasPosted}">
      <li><a href="{xen:link search/search, '', 'type=post', 'thread_id={$thread.thread_id}', 'users={$visitor.username}'}">Your Posts</a></li>
</xen:if>
 
Top Bottom