How To Set Links of a Linklist widget Open in a New Window

Posted by Lasantha Bandara File Under : html 8 Comments

1.Login to your dashboard--> layout- -> Edit HTML

2.Click on "Expand Widget Templates"

3.Scroll down to till you see your Link list code :

(Note : You may also can find it by searching <b:widget id='LinkList )

Look at the example below.

<b:widget id='LinkList12' locked='false' title='Recomended Links' type='LinkList'>
<b:includable id='main'>

<b:if cond='data:title'><h2><data:title/></h2></b:if>
<div class='widget-content'>
<ul>
<b:loop values='data:links' var='link'>
<li><a expr:href='data:link.target' target='_blank'><data:link.name/></a></li>
</b:loop>
</ul>
<b:include name='quickedit'/>
</div>
</b:includable>
</b:widget>

Now put blue colored code ( target='_blank' ) as the example below into your Link list code.

<b:widget id='LinkList12' locked='false' title='Recomended Links' type='LinkList'>
<b:includable id='main'>

<b:if cond='data:title'><h2><data:title/></h2></b:if>
<div class='widget-content'>
<ul>
<b:loop values='data:links' var='link'>
<li><a expr:href='data:link.target' target='_blank'><data:link.name/></a></li>
</b:loop>
</ul>
<b:include name='quickedit'/>
</div>
</b:includable>
</b:widget>

Important : You must include the space before target='_blank' as the example above.

Now save your template and you are done.

8 thoughts on “How To Set Links of a Linklist widget Open in a New Window

  1. Is there a way to target a particular link on the Menu. I just want "Gameplays" on my link list to open in a new tab. Can you please let me know if you can help? would really appreciate it.

    Thank you

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.