0

I am using search api views to override core taxonomy term pages. I would like to create a view that displays parent term content as well like a related content block. Or as a view I can use when results are empty.

I am not able to achieve this so far. I have tried the Parent terms (indexed) filter using every default argument combination I can think of. I have tried the indexed taxonomy terms filter also using every default argument I could imagine. What I assumed would be a very simple views has turned out to be rather complicated. I am starting to wonder if it is actually not a configuration problem at all but related to search api and might not even be possible in the first place.

1 Answer 1

0

Please follow the steps to show content of Parent Term on current Term.

  1. Create a view as block
  2. Add relationship as Parent Term
  3. Add contextual filter as Term ID using the relationship and set it like this
  4. Add filter criteria as Taxonomy Vocabulary using the relationship
  5. Add fields whatever you have in taxonomy and use relationship as well

You can also follow the steps in the pics I've created for you. enter image description here

You don't need to create a new view to show the content of current taxonomy, you can set manage display. Go to admin/structure/taxonomy/TAXONOMYNAME/display

While if you want to display using view, then create another view and follow these steps:

  1. Add contextual filter as Term ID and set it like this
  2. Add fields of the taxonomy you want to show

Note that we won't use any relationship in this view

Now, go to in the block configuration admin/structure/block and enable these.

I hope this will work for you

1
  • thank you for the detailed answer. unfortunately, my view uses search api indexed fields and it does not appear that some of your filters and relationships are available. Commented Mar 6, 2018 at 17:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.