We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 3232
    • 380 Posts
    I found ListChildOrSibs but was wonder if ditto could do this...

    I have a ditto call that displays all children of a parent (items currently in this section) the problem with this is that the document you are currently on is displayed in the list.

    Is it possible to create a call that will only display a documents siblings and not display itself in the results?

    Thanks
    Brian
      • 18397
      • 3,250 Posts
      Yes, just add &filter=`id,[*id*]` to your Ditto call.
        • 3232
        • 380 Posts
        I am already using a filter in this particular call... is there anyway to use two filters at once?
          • 18397
          • 3,250 Posts
          Yes, use a | (pipe) character between them
            • 3232
            • 380 Posts
            I can’t seem to get it to work... here is my call...


            [!Ditto? &startID=`[[getParentId]]` &summarize=`5` &total=`5` &tpl=`ListingTemplate` &showPublishedOnly=`1` &descendentDepth=`1` &sortBy=`menuindex` &sortDir=`ASC`  &filter=`tvCurrentIssue,Yes,= | id,[*id*]` !]
              • 18397
              • 3,250 Posts
              &filter=`tvCurrentIssue,Yes,= | id,[*id*]`

              needs to be
              &filter=`tvCurrentIssue,Yes,1|id,[*id*]`
              


              Note that there are no spaces between 1 and id. (The parser will remove equal signs so you must use the corresponding filter numbers)


              FYI: If get parent just gets the parent of the document you can simply use [*parent*] there for a small speed boost.
                • 3232
                • 380 Posts
                Almost there...

                turns out that the call you supplied above only pulls in the document you are currently on. when I changed that part of the call to the following it displayed it correctly.

                &filter=`tvCurrentIssue,Yes,1|id,[*id*],2`



                Thank you so much for all of your help, its amazing how the tiniest of things can really muck things up.