Trying to create a view block with a list of five links

  • Event Details (dynamic)
  • Cause (dyanmic)
  • Sponsors (statis)
  • Volunteer (static)
  • Register (static)

Dynamic url will look like this:



I am not able to format the taxonomy term to use it in the url

Creating a view with a dynamic link from taxonomy term

Taxonomy term prints as: The William Dennis Memorial Golf Tournament (with capitals and spaces)

View looks like this: Each field is a rewrite to produce a link - that is except Year and Golf Tournament, which are the tokens to be replaced in the url

** Solution ** * Not sure if this is the 'right' way *

Added contextual filter for: Content: has taxonomy term ID

But it doesn't appear to use the taxonomy term....so really I providing a value from the url

Raw value from URL

Then I messed around with tokens, first trying [token_taxonomy_term] <--- not actual token; %1 and !1 <---- all of these exist in the available Replacement Patterns

Replacement Patterns

Here is the rewrite I used to rewrite the url for 'cause'

  • What happens if you try to use one of the validation filters offered by the contextual link to replace spaces with dashes? – beth Aug 18 '14 at 16:48
  • When I add contextual filters all contents of the view disappear. – islalobo Aug 18 '14 at 16:50
  • What contextual filters are you adding and how are they configured? – beth Aug 18 '14 at 16:51
  • configuration added to issue – islalobo Aug 18 '14 at 16:55
  • What happens if you enter the term in the preview field on the view instead of the default field on the contextual filter? Also, which type of contextual filter is this? – beth Aug 18 '14 at 17:02

In the contextual filters you may have to add the Context: Has taxonomy term ID filter. You can set the Specify validation criteria settings. The validator option is usually Taxonomy Term, but other validator options are available. Make sure to choose Term Name converted to Term ID, as this is what is needed to be passed for to the url. Also check the Transform dashes in URL to spaces in term name filter values checkbox underneath. Choose your action to take if the filter value does not validate dropdown.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.