The Custom Token form.
The Custom Token Type form.
The custom tokens list.

It gives the user the ability to create custom tokens for specific replacements that can improve other modules relying on the Drupal 7 token API or, for Drupal 6, the Token module.

Versions 7.x-1.x and previous relied on PHP evaluation to build custom tokens.

The new 7.x-2.x relies on input filters. While still allowing for PHP tokens through the D7 core PHP filter module, administrators can permit only HTML or plain text custom tokens.

New features in version 7.x-2.0

  • Build tokens using input filters (#1336622)
  • Define custom token types (#1341106)

Versions 7.x-1.x and previous

They are designed for developers with, at least, a little PHP knowledge. Custom tokens will evaluate and execute PHP snippets in order to provide the replacements for the tokens you define.

Version 8.x-1.x

For security, PHP snippets are not supported.

Related modules

Dependencies

Token

Alternative modules

  • The Parameters module makes parameters available as tokens and are completely configuration-based (exportable / importable through configuration). Major difference that a parameter token always starts with [parameter:*] whereas this module allows specifying a token type on root level.

Sponsored by (versions 5.x and 6.x)

Infomagnet

Sponsored by (versions 8.x)

Drupal Geeks
DROWL.de

Supporting organizations: 
They helped by running code sprint
Sponsored the refactor of D8 version as a content entity
Ongoing support for Drupal 9/10
proudly helps to maintain this module for the Drupal community

Project information

Releases