Stash
ExpressionEngine 2, ExpressionEngine 3, ExpressionEngine 4, ExpressionEngine 5, ExpressionEngine 6
Back to this add-on's main page
View Other Add-ons From Mark Croxton
Listing entries per category, grid not parsing
Support Request
Ngon Com
|
Posted: 13 July 2018 10:04 AM |
|
|
|
Hi Mark,
As your mention here: https://github.com/croxton/Stash/wiki/Listing-entries-per-category
It works well, but my entry have grid field, stash can’t capture data inside grid:
{exp:channel:entries channel="blog" dynamic="no" disable="member_data|pagination|category_fields"} {categories} {exp:stash:append_list name="blog" context="{category_id}"} {stash:this_title}{title}{/stash:this_title} {stash:this_url_title}{url_title}{/stash:this_url_title} {stash:this_body}{blog_body}{/stash:this_body} {this_grid limit="1"} {stash:this_grid_file}{this_grid:file}{/stash:this_grid_file} {/this_grid}
{/exp:stash:append_list} {/categories} {/exp:channel:entries}
Output ”{stash:this_grid_file}” not parsing:
{exp:channel:categories channel="blog" style="linear" disable="category_fields" show_empty="no"} <h2>{category_name}</h2> <ul> {exp:stash:get_list name="blog" context="{category_id}"} <li> <a href="/blog/{this_url_title}"> <h2>{this_title}</h2> <p>{this_body}</p> <p>Not parsing: {this_grid_file}</p> </a> </li> {/exp:stash:get_list} </ul> {/exp:channel:categories}
Thank so much!
|
|
|
|
Ngon Com
|
Posted: 13 July 2018 09:52 PM |
# 2
|
|
|
Oh, my mistake is focus to append_list and forget set_list, another way I using match + again to solve problem.
Thank Mark!
|
|
|