We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4295
    • 98 Posts
    Can someone tell me how to access a document’s keywords using Ditto’s filter parameter? I’d prefer to use the filter parameter and not a TV, if at all possible. I’m trying to filter for results where the pagetitle of the Ditto call document matches a keyword of the documents within the startID folder. If this is unclear, please let me know and I’ll rephrase. One of a gabillion versions I’ve tried below. Please haaaaaalp if you can! Thanks.

    &filter=`keywords,[*pagetitle*],1`


    DropMenu had the &keywordRegexp parameter and the ListRelated snippet filters by getkeywords. Is there no way to filter by a documents existing keywords in the powerful Ditto?
      • 18397
      • 3,250 Posts
      You need to use the tag based parameters as the keywords are combined into a delimited list. So you need &tags, &tagData, and &tagMode. Please look at the documentation for information on how to use them.
        • 4295
        • 98 Posts
        Yeah, I created a TV that grabbed the keywords and tried using that in Ditto tags but could never get it to work. The keyword TV was working fine and correctly returned the keywords, as I tested the output -- I don’t know what the problem was. I think I was using something like...

        [tt]&tagData=`tvKeywordMatch` &tags=`[*pagetitle*]` &tagDelimiter=`,` &tagMode=`onlyTags`[/tt]

        Anyway, since the updated ListRelated now supports the startID parameter, I ended up using that for my solution -- although I would have preferred to use Ditto instead.
          • 18397
          • 3,250 Posts
          You would have needed to use keywords as the tag data as that tells Ditto to go get the keywords and parse them in a certain manner.
            • 4295
            • 98 Posts
            Maybe I misunderstood your post, but what you suggest sounds like what I said I did in my previous post. Anyway, I think I have a workaround now.
              • 18397
              • 3,250 Posts
              You used tvkeywords. I mean use the word keywords without tv.
                • 4295
                • 98 Posts
                Oy! You mean it would have been that simple! Wow. Thanks Mark, I’ll play with that again when time allows. I love Ditto, it seems to be able to do most anything. I had created a TV that sucked in the keywords and the TV worked correctly, so I’m still not sure why that didn’t work -- but just using the word "keywords" is much better grin