We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 21502
    • 16 Posts
    Say I have a simple blog that has a TV created for tagging, and:

    The TV allows values A, B, C, and D.

    blog post 1 is tagged as topic A and B
    blog post 2 is tagged as topics B and D
    blog post 3 is tagged as topics A and D

    How do I create a query that will return all posts tagged as A, i.e. blog posts 1 and 3 but not 2?

    Thanks in advance,

    Jonathan
      • 36592
      • 970 Posts
      Use TvTagCloud snippet.
      http://modxcms.com/extras.html?view=package/view&package=473
        • 16278
        • 928 Posts
        Are you using Ditto? If so, the Tagging extender does this pretty simply for a fixed category:
        [!Ditto ... &tagData=`myTVname` &tags=`A` ... !]

        If your listing uses the [+tagLinks+] placeholder, the links will filter in the tag you click on (instead of the fixed &tags parameter].
        Or you can do it via the URL query string: www.example.com/blogpage.html?tags=A.
        The Tagging extender is hooked in automatically when you set the &tagData parameter.
        cool KP
        (See draft notes at http://www.pogwatch.com/ditto/ditto-extenders/ditto-tagging.html)
          • 21502
          • 16 Posts
          Thanks! I’ll give these methods a try and see what happens.