Hi,
I would like to rewrite the output of a Taxonomy term field. In particular, to add a class to the html "a" tag. So i used:
<a href="/taxonomy/term/[term:tid]" class="customclass" id="customid">[node:field_name]</a>
When I add this field with this particular formatter to a panel wich is a Node page (a rewrite of the classic Article content type), [node:field_name] is displayed correctly, but [term:tid] doesn't appear.

Any hint?

Thank you in advance

Comments

Deciphered’s picture

Issue summary: View changes
Status: Active » Fixed

[term:tid] would only work if you where rendering your formatter on a field being displayed on a Taxonomy term. You are after the value of the Taxonomy term field, which would be something more like: [node:field_term] or whatever your field is called.

Although, that likely doesn't work properly either due to the issue with Field tokens in D7; #1511830: Fix Token engine.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.