0

I am looking to create a QUESTIONS view for all terms in a taxonomy vocabulary. Let's say I have a taxonomy that has terms apple, orange, banana. We use pathauto to go to domain.com/apple which shows one content type.

But what I am trying to do is create a sub page for each term with the path: domain.com/apple/questions

I have already set the view and added a contextual filter but for some reason, its is not working.

The path that I have for the view is (/taxonomy/term/%/questions)

Is this correct? Am I approaching this the right way? If you have a better suggestion please let me know.

1
  • You stated you're using path with an argument. Have you set up the Contextual filter for that argument? It won't work without it. Is this a new display on the existing Taxonomy term (Content) Views, or did you clone it?
    – prkos
    Commented Jun 9, 2018 at 22:55

2 Answers 2

0

The Panels module provides the views content panes which is a display type for views, there you can create your view easily, make it fetch input argument from context and show the results, then you can simply include your pane in the place you want.

if you are not much familiar with Panels module, then this tutorial can make you became familiar, hence this is for Drupal 7 but you can use it in drupal 8 as well.

0

If I understood your question, you do not need to create any view nor change the default taxonomy term view. You just need to create a path alias pattern for taxonomy terms of that particular vocabulary - something like this: /term-name-token/questions.

3
  • Hi thanks for the reply. You are correct but I want to create tabs for questions, reviews, photos for the taxonomy vocabulary. All those various content types need to be shown under the taxonomy term page in as tabs.
    – Progonat
    Commented Jun 13, 2018 at 4:04
  • Why don't you do this way: 1) use an exposed filter of content types instead of a contextual filter; 2) with better exposed filters module display the options of the exposed filter as links and style it as tabs. Commented Jun 13, 2018 at 15:09
  • I guess that would work in theory, but the content will be preseneted in different format. So I would rather have tabs and format the view or use DS for that particular content type.
    – Progonat
    Commented Jun 13, 2018 at 15:11

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.