How to create an anchor link per node in Drupal views

Standaard

Creating anchor links in views in Drupal can be very easy. You can to it this way:

  • In the view render the output as fields.
  • Add the field ‘Content: path’.
  • Open the fieldset ‘Rewrite results’.
  • Check the rewrite output checkbox.
  • Enter the following text in the rewrite output textarea:
    • <a href='[path]#youranchor’>Your custom link text</a>

The [path] token is the path alias of the node and can be found in the replace patterns section.