Difference between revisions of "Liquid Template Variables - linklists"
From Spiffy Stores Knowledge Base
(New page: The liquid variable '''linklists''' contains a collection of all of the store's linklists. A linklist is ...) |
m |
||
(2 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | The | + | The Liquid template variable '''linklists''' contains a collection of all of the store's [[Liquid_Template_Variables_-_linklist|linklists]]. |
A [[Liquid_Template_Variables_-_linklist|linklist]] is a list of collected [[Liquid_Template_Variables_-_link|links]]. | A [[Liquid_Template_Variables_-_linklist|linklist]] is a list of collected [[Liquid_Template_Variables_-_link|links]]. | ||
Line 5: | Line 5: | ||
Navigation menus are created using '''linklists'''. | Navigation menus are created using '''linklists'''. | ||
− | You can access any '''linklist''' by using the linklist handle to index the linklists contained within the '''linklists''' variable. | + | You can access any '''linklist''' by using the linklist handle to index the '''linklists''' contained within the '''linklists''' variable. |
<pre><ul> | <pre><ul> | ||
Line 14: | Line 14: | ||
In this example, we generate a list of all links in a '''linklist''' called ''navigation''. | In this example, we generate a list of all links in a '''linklist''' called ''navigation''. | ||
+ | |||
+ | == Further Reference == | ||
+ | |||
+ | * [[Liquid Basics]] | ||
+ | * [[Liquid Tag Reference]] | ||
+ | * [[Liquid Filter Reference]] | ||
+ | * [[Liquid Variable Reference]] | ||
+ | * [[Liquid Paginate Tag|Pagination ]] |
Latest revision as of 12:13, 25 June 2018
The Liquid template variable linklists contains a collection of all of the store's linklists.
A linklist is a list of collected links.
Navigation menus are created using linklists.
You can access any linklist by using the linklist handle to index the linklists contained within the linklists variable.
<ul> {% for link in linklists.navigation.links %} <li>{{ link.title | link_to: link.url }}</li> {% endfor %} </ul>
In this example, we generate a list of all links in a linklist called navigation.