Linklists

From Shopify Wiki

Jump to: navigation, search

The liquid variable linklists contains a collection of all the linklists in this shop. A linklist is (as the name describes) a list of collected links (see link!). A navigation menu would be a good example of a linklist.

You can access a linklist by calling its handle on linklists.

Example usage:

<ul>
{% for link in linklists.navigation.links %}
   <li>{{ link.title | link_to: link.url }}</li>
{% endfor %}
</ul>

This returns a list of all the links in a linklist called navigation (and also runs them through a filter | link_to: link.url that sets the corresponding hyperlink for each linkname.

Personal tools