Question

I have the usual suspects in place. Have taxonomy such as:

+Guys
--Core Collection
--New Arrivals
-- etc, etc
+Girls
--Core Collection
--New Arrivals
-- etc, etc
+Sale Items

You get the idea here. Anyway, i have taxonomy menu building paths (with path alias) like "/collection/guys/core-collection/some-clothing-name". I want to build a custom view so that the path displays the view with taxonomy terms as they arguments to filter on. Anyone have any information on how to pass 2 arguments from the url to filter out the items of clothing? trying now to have to build my own module but it seems i may have to go down that road.

ideally, i'd like to have "collection/%/%". Thanks for the help.

Was it helpful?

Solution

You'll have to convert the term names to term IDs. I'm not going to take credit for the solution but there is a post where it describe how you can solve the transformation from term name to term ID.

Rafael already suggested how to approach the path alias, so I think that chapter is covered.

Source: http://groups.drupal.org/node/8500

OTHER TIPS

Let me see if I understand. You want a view to show, for example, all items on the guys/core-collection category, right? See if this works:

  1. Enable the "taxonomy" view that comes by default with the views module (the one that takes taxonomy/term/% as arguments)
  2. Configure the path alias for every taxonomy term of that vocabulary using the "pathauto" module to be "collection/[catpath-raw]", this way you'll get the whole term hierarchy rendered into the alias
  3. That's it, you'll just need to link to "taxonomy/term/(tid)" and the alias will be automatically displayed on the URL. This will also work on every link for a term of that vocabulary on the site.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top