I am using Drupal 8.3.1 and using the module File (Field) Paths to define the path and filename. I want to use the value of a taxonomy field (Entity reference in CCK) in the same content type as part of the filename. The machine name of the field is field_organization and doing [node:field_organization] produces an href link where I want is just the name of the single value it contains. How do I get only the term's name instead?
1 Answer
Try to append :value
to the field:
[node:field_organization:value]
For a reference field something like this:
[node:field_organization:0:entity:name]
If you want to look up all available tokens install the Token module and go to /admin/help/token.
-
Thank you! Is there any way to have tokens be transformed (spaces removed for example)? I want to avoid PathAuto as to not affect both filenames and urls. Apr 20, 2017 at 13:11