I have a navigation menu displaying product categories. Each first level category has a different color defined in TV called scheme. I wanted to apply css class to all main menuitems (parents without children).
So I made this simple call:
[[Wayfinder? &startId=`8` &rowTpl=`have a `]]
and a chunk menu.item:
<li [[+wf.parent:is=`8`:then=`class="cat[[+scheme]]"`]]>
<a href="[[+wf.link]]" title="[[+wf.title]]">
[[+wf.linktext]]
</a>
[[+wf.wrapper]]
</li>
for some reason class wasn't applied to LI, but funny thing is that, when I added [[+scheme]] inside link beside [[+wf.linktext]] that class filter inside LI started to work ??
So basically this works !! but i don't want to have that scheme beside title:
<li [[+wf.parent:is=`8`:then=`class="cat[[+scheme]]"`]]>
<a href="[[+wf.link]]" title="[[+wf.title]]">
[[+wf.linktext]] [[+scheme]]
</a>
[[+wf.wrapper]]
</li>
I solved this proble with custom snippet, but it bugs me what is wrong with previous solution??
Another question .. is there a way to define differnet rowTpl for first level ?