1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.1 link threads open in a new tab?

Discussion in 'Troubleshooting and Problems' started by wichern.k, Sep 6, 2012.

  1. wichern.k

    wichern.k Member

    link threads open in a new tab?
    insert (target="_blank") in file?
  2. Brandon Sheley

    Brandon Sheley Well-Known Member

  3. wichern.k

    wichern.k Member

    <div class="nodeText">
                <h3 class="nodeTitle"><a href="{xen:link link-forums, $link}" data-description-x="#nodeDescription-{$link.node_id}" target="_blank">{$link.title}</a></h3>
                <xen:if is="{$link.description}"><blockquote class="nodeDescription muted baseHtml" id="nodeDescription-{$link.node_id}">{xen:raw $link.description}</blockquote></xen:if>
    I edit node_link_level_2 not successful.:(
  4. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Which link do you want to change? Can you give an example?
  5. wichern.k

    wichern.k Member

    What I want is every time when you wanna press any thread it could be open in a new tap as well.
    ( not only a sub-topic can open new tap)
  6. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Admin CP -> Appearance -> Templates -> thread_list_item

    Add the red code:

    				<xen:else />
    						{xen:helper threadPrefix, $thread}
    				<a target="_blank" href="{xen:link "threads{xen:if '{$thread.isNew} AND {$thread.haveReadData}', '/unread'}", $thread}"
    					title="{xen:if '{$thread.isNew} AND {$thread.haveReadData}', {xen:phrase go_to_first_unread_message}}"
    					class="{xen:if $thread.hasPreview, PreviewTooltip}"
    					data-previewUrl="{xen:if $thread.hasPreview, {xen:link threads/preview, $thread}}">{xen:helper wrap, $thread.title, 50}</a>
    				<xen:if is="{$thread.isNew}"><a href="{xen:link threads/unread, $thread}" class="unreadLink" title="{xen:phrase go_to_first_unread_message}"></a></xen:if>
    wichern.k likes this.
  7. wichern.k

    wichern.k Member

    This is what I find. Thank you so much.

Share This Page