• Resolved georgschroeder

    (@georgschroeder)


    Hello,
    if I add a category and a tag in one conditional logic block, the sidebar is already shown when one of the two conditions is fulfilled (either the tag or the category or both). However, what I want is, that the sidebar only appears, when both conditions are fulfilled, that is a post has a specific tag and is of a specific category, but I can’t get it working. Can you help me out?

    Thanks a lot!

    Best

    Georg

    https://wordpress.org/plugins/content-aware-sidebars/

Viewing 1 replies (of 1 total)
  • Plugin Author Joachim Jensen

    (@intoxstudio)

    Thank you for reporting this.

    I am aware of this case, and it will eventually be fixed. The problem is that both category and tag are of the same content type (taxonomy), and even though the UI says “and”, content of the same type is currently being treated as “or”. This also means that you can put posts and pages in the same condition group.

    In the most recent versions of WordPress, taxonomies has internally been changed, so it is now performance wise feasible to change this behaviour. I am still figuring out how to roll the change into the plugin without breaking users’ setup.

    For now, you can fix the problem by creating 2 sidebars.
    – Category Sidebar should replace your Main Sidebar on selected categories.
    – Tag Sidebar should replace Category Sidebar on selected tags.

    With this setup, the Tag Sidebar will only be displayed on the posts where the Category Sidebar is. I hope this makes sense.

    Let me know if you have any questions.

Viewing 1 replies (of 1 total)
  • The topic ‘Category and tag with AND condition not working correctly’ is closed to new replies.