2

Is it possible to create a view that uses both taxonomy terms and the node title or nid as contextual filters?

Ideally this would mean that you could have one view that just handled the taxonomy terms eg. the parent-taxonomy-term/child-taxonomy-term view would display all the nodes matching those taxonomy terms and parent-taxonomy-term/child-taxonomy-term/node-title would display a different view with more information on the specific node returned.

Is such a view possible and if so how would i set it up (all my experiments at this have failed)?

The reason I require this is that I wish a view of the same node to be accessible via a number of different taxonomies. I am creating a store where users can see the same gold diamond ring by navigating on the main dropdown menu via 'Jewellery > Rings', 'Gemstones > Diamond' or 'Metal > Gold'. While the user is navigating in this way the breadcrumb trail and url are looking good 'jewellery/rings' etc. But when a product is clicked on and its node is viewed it has its own url that can only fit the pattern of one of the taxonomies. So the breadcrumb trail would suddenly change when getting to the product via another taxonomy.

1

1 Answer 1

0

I wasn't able to find a neat solution to this problem.

What I ended up doing was manually creating a page view from each taxonomy e.g. metals/gold/% and passed it the node title through contextual filters. This meant I was able to create a view of the correct product and the Easy Breadcrumb trail still looked good and a single product may exist in multiple breadcrumb trails. This works but isn't an elegant solution.

It would be great to find a solution to this that didn't need manual creation of page views. So any further thoughts on this are appreciated.

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.