We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 6726
    • 7,075 Posts
    It’ the first time I am using the &showSubDocCount parameter and I can’t seem to have it working huh
    (Using WF 2.0)

    I have added &showSubDocCount=`1` to my Wayfinder call,

    [!Wayfinder? &startId=`5` &level=`1` &showSubDocCount=`1` &rowTpl=`rowTplBlog`!]


    and added the [+wf.subitemcount+] placeholder to my rowTpl like this :

    <li[+wf.id+][+wf.classes+]>
    	<a href="[+wf.link+]" title="[+wf.title+]" [+wf.attributes+]>[+wf.linktext+] ([+wf.subitemcount+])</a>
    	[+wf.wrapper+]
    </li>
    

    I first thought of a cache issue and I tried :

    • snippet cached, page cached
    • snippet uncached, page cached
    • snippet cached, page uncached
    • snippet uncached, page uncached

    And I still get a 0 count.
    Child documents are published...

    What am I missing ?

      .: COO - Commerce Guys - Community Driven Innovation :.


      MODx est l&#39;outil id
      • 6726
      • 7,075 Posts
      Sorry to bump, but anyone has an idea ?

      Edit : I have switched off PHx just in case, but to no avail...
      Also re-checked the doc and I really can’t figure what I am doing wrong, it’s frustrating !
        .: COO - Commerce Guys - Community Driven Innovation :.


        MODx est l&#39;outil id
        • 8894
        • 114 Posts
        Hi David,

        I don’t know why, but it is linked to &level=`1`.
        When I change 1 to 4 for example, it works ...
          • 6726
          • 7,075 Posts
          Now that you say it, it makes perfect sense... I you limit levels to 1 it’s only natural that Wayfinder counts only the first level (category folder in my case).


          Edit :
          It works indeed and but I’ll have to uncheck the display in menu flag so that they don’t appear in the menu...

          Edit 2 :
          Hmm... unchecking them made the problem re-occur it seems that if child document are not meant to be in the menu, they’re not counted sad

          Edit 3 :

          Finally I got this, you have to use the &hideSubMenus parameter for this to work with child document menu flag checked.

          Thanks for unlocking me on this one !!!
          ;D
            .: COO - Commerce Guys - Community Driven Innovation :.


            MODx est l&#39;outil id
            • 18044
            • 10 Posts
            Quote from: davidm at Mar 05, 2008, 08:54 AM
            Finally I got this, you have to use the &hideSubMenus parameter for this to work with child document menu flag checked.

            Great decision. Thanks davidm. I thought there is a need to write own snippet to make calc of children elements. But now it’s ok.
              Допустим так, сюда туда,
              Будет так ни так, ни сяк.
              Ну не так, чтоб уж туды,
              Запроси сюды.
              Как бы так, чтобы не сяк,
              Эдак, водак, мяк и шмяк,
              Залепить сюда вот-так,
              Получается - Косяк.