Quote from: craigbeck at May 04, 2008, 03:38 PM
[!ListSiteMap?LSM_root=0!] with cacheable and uncacheable
[[listSiteMap]] with cacheable and uncacheable
[!ListSiteMap!] with cacheable and uncacheable
Have you tried setting the levels with the snippet,
[tt][[listSiteMap?LSM_levels=2]][/tt]
Changing "2" to the number of levels you want the children documents to show
Hi craigbeck, thanks for the tips.
I finally got back to working on this snippet for a site just now, and yes I tried t[tt][[listSiteMap?LSM_levels=2]][/tt], still it doesn’t work even with levels=3 (my document structure is 3 levels deep)
However I found a way for it to show up now, but is curious if this is actually a bug or it’s something I still don’t understand how this snippet works.
First it’s still the same site that I tried to implement the menu. Initially client wanted drop-down menu but with two levels only, so I have the ’Show in Menu’ unchecked for third level page in the document.
Client changed her mind with drop-down menu, but I still kept the ’Show in Menu’ unchecked for third level (published) but keep the second level unpublish.
After trying all combination I was still not able to bring the third level shows up; the 2nd level (just served as a container with no content for the page) shows up when I do this : $showUnpubs = 1;
but with ’$showUnpubs, whether I set it to ’0’ or ’1’, it’s still now working.
So I thought perhaps I should have the ’Show in Menu’ checked in the document. As soon as I did that, the third level shows up.
So now it solved my problem, but it still remains for future sites that want to use drop-down menu with level controls.
update: I took a closer look at the code, is this what is causing it?
if ((!$su && !$child[’published’]) || ($child[’deleted’]) || (!$showNotInMenu && $child[’hidemenu’])) continue;