Has anyone done much to customize the behavior of the smart breadcrumbs?
I'm looking at two things at the moment:
I can see that it's looping over the information but I can't tell if it's generating the array or iterating over the array.
Then for #2 I want to adjust the way it dynamically adds the links, that way I can divert the crumbs where I want them to go. As it stands if there's a page in the list, it won't be read by the breadcumbs.
>> EDIT 20210303_1024 <<
I found this in the Code Samples, it seems (on the face of it) like it might help. It looks like it's setting the current category and then setting the parent category. Am I reading this right?
https://docs.miva.com/code-samples/p...tegory-childof
I'm looking at two things at the moment:
- Looking for how the "breadcrumb:links" array is generated.
- How to make the link pattern go to a url instead of a category
Code:
<mvt:foreach iterator="cats" array="breadcrumbs:links"> <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem"><mvt:if expr="l.settings:cats:name EQ '...'"><span itemprop="item" class="cats-hidden"><span itemprop="name">&mvt:cats:name;</span></span><span class="breadcrumb-border">/</span><mvt:elseif expr="l.settings:cats:code EQ l.settings:breadcrumbs:current_item:code"><span itemprop="item" class="current-item"><span itemprop="name">&mvt:cats:name;</span></span><mvt:else><a itemprop="item" href="&mvt:cats:link;"><span itemprop="name">&mvt:cats:name;</span></a><span class="breadcrumb-border">/</span></mvt:if> <meta itemprop="position" content="<mvt:eval expr="POS1"/>" /></li> </mvt:foreach>
Then for #2 I want to adjust the way it dynamically adds the links, that way I can divert the crumbs where I want them to go. As it stands if there's a page in the list, it won't be read by the breadcumbs.
>> EDIT 20210303_1024 <<
I found this in the Code Samples, it seems (on the face of it) like it might help. It looks like it's setting the current category and then setting the parent category. Am I reading this right?
https://docs.miva.com/code-samples/p...tegory-childof
Comment