I have a two level tree structure consisting of a load of folders with pages within. One folder has a third level of pages but I don’t want to show these in the menu. I’ve used the following snippet call to display the menu:
[!Wayfinder? &startId=’0’ &level=’1’ &hideSubMenus=’1’ &parentRowTpl=’wfMenuImage’ &rowTpl=’wfMenuItem’ &outerTpl=’wfContainer’!]
The menu displays exactly how I’d imagined it would. But I have created some chunks to replace the top folder item text name with an image as follows:
<li[+wf.classes+]>
<a href="[+wf.link+]" title="[+wf.title+]"><img src="/assets/images/mnu-[+wf.id+].png"/></a>
[+wf.wrapper+]
</li>
But for some reason none of the chunk code is being used! I’ve checked and double checked the names, they are spot on and I’ve rather stumped now. Any suggestions to what the solution could be?
Hi,
you are using simple quotes for the snippet params.
Replace them with backticks ``
[!Wayfinder? &startId=`0` &level=`1` &hideSubMenus=`1` &parentRowTpl=`wfMenuImage` &rowTpl=`wfMenuItem` &outerTpl=`wfContainer`!]
:-)
Oh dear. Keep this one quiet eh! Thanks for the quick reply.
Actually one more quick question. Is there any way to access the documents alias using wayfinder? Would prefer using that to id for image naming conventions.
Example: I’d rather use mnu-about.png than mnu-2.png (2 being the docid).
However I think the Alias plugin should do the trick. Cheers for your help!
I’m having the same problem. I’ve verified which ticks I’m using and I have the correct ones. I changed the innerTpl chunck to not use the [+wf.link+] and coded it for the same id as a test. All four links still render with the correct URLs instead of the hardcoded id. This is how I know that it is ignoring the custom innerTpl chunk.
InnerTpl:
<li[+wf.id+][+wf.classes+]>
<a href="javascript:loadintoIframe(’myframe’, ’[~109~]’)" [+wf.classes+] title="[+wf.title+]" [+wf.attributes+]>[+wf.linktext+]</a>
[+wf.wrapper+]
</li>
Snippet Call:
[!Wayfinder? &startId=`[*id*]` &level=`1` &outerTpl=`Tabsouter` &innerTpl=`TabsInner5` !]