Link Context is an add-on for Link Attributes widget.

Link Attributes widget provides means to add custom attributes to links in link fields. Link Context makes use of that feature by adding two attributes "Prefix" and "Suffix" that allows you to add exactly that: a prefix and a suffix for your link.

So instead of having a link list with just linked texts like

you can enhance the links by adding a context

  • Visit the Drupal site.
  • Looking for a specific function? See the PHP manual!

I once wrote a patch for the contrib Link module in Drupal 7 (see #1485440: Allow user to add text before or after link tag (prefix/suffix)) which didn't make into the main module and thus didn't land in Drupal 8 core. However, I used the patched version for quite some projects and required a D8 version of that.

Supporting organizations: 
funded the development.

Project information

Releases