Drupal 7: filter by two or more taxonomy terms
Is there any way to filter content by two or more taxonomy term. For example: I've 开发者_如何学Gogot two vocabularies: car brand(Toyota, BMW, Ford) and car type(crossover, sedan, bantam car). How i can create filters like: Toyota&sedan, Ford&crossover etc?
The easiest way to accomplish this would be to use the Views modules. This module allows you to create complex custom displays of any of your content.
Basically you will create a View. Each View can have multiple Displays. Displays can be either pages or blocks. In your case you will want to create a page. Once you've created the page, you can add what are called Filters. Filters allow you to pass in variables to that page, which will limit the returned results.
I apologize for the misleading earlier response. I think it may now be more clear the path I was taking you down. Once you feel comfortable with Views, have a look at my previous response below.
OLD RESPONSE: You should be able to create two filters, one for each vocabulary. Then select one or more terms in each filter. Or have them exposed and select this way. There are many options here, you should play around a bit more in Views.
Take a look at the "Content: Has taxonomy term" filter specifically.
精彩评论