Taxonomy Token only provides "node" type tokens, i.e., tokens that expose taxonomy details related to a specific node.

Should it provide "taxonomy" type tokens also? Can someone interested explain exactly what each token would expose in a "taxonomy" context?

Comments

OneTwoTait’s picture

It would be useful for me.

Uses I can think of:
1) Creating more useful page titles with the Taxonomy Token and Page Title modules. As a simple example, instead of having a page title like "Thailand, Hotels" I could setup a page title pattern that would read "Hotels in Thailand".
2) Creating more intuitive and SEO-friendly URLs. Following the example above, if "hotels" and "Thailand" were two terms in "category" and "location" vocabularies, a URL like .com/thailand/hotels could automatically be generated with Pathauto.

These are the reasons I tried out Taxonomy Token.

rsevero’s picture

I wonder how exactly these tokens would look like.

Would there be term1, term2, term3 tokens and so on?

OneTwoTait’s picture

Yes, from a usability perspective, I suppose the token used could be like [vocab:1:term] and that would display a term from vocabulary 1.

rsevero’s picture

I don't believe this would work. Which term in the term chain would be presented with [vocab:1:term]? The first? The last? The second?

I believe it would be necessary to create something like [vocab:1:term:1], [vocab:1:term:2] to present the top most term of vocabulary 1 and the second top most term of vocabulary 1 respectively.

The problem with such an approach is that for different taxonomy depths there would be different tokens available.

Ideas?

OneTwoTait’s picture

Maybe just show the top term in the vocabulary. It's simpler but still pretty great.

rsevero’s picture

Well, maybe there could be [vocab:1:term] and [vocab:1:bottomterm] in taxonomy context, like in node context. The first would return the top term and the second would return the bottom term. What you think?

Is there already a token that provides each vocabulary name in taxonomy context?

OneTwoTait’s picture

Works for me.

I'm not aware of tokens that provide vocabulary names.