Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
This project is not covered by Drupal’s security advisory policy.
The basic idea is that when one defines the token they add an addition param of function which is a callback to be used.
$info['tokens']['f']['cap'] = array(
'name' => t('Capitalize'),
'description' => t("Capitalizes the value. ") . token_function_help(1),
'dynamic' => TRUE,
'function' => 'strtoupper',
);
so cap would take what ever the X in [f:cap:X] and capitalize it.
one can use multiple params separated by :
and one can use tokens but they need to be wrapped in {} instead of []
Project information
- Module categories: Developer Tools
- 5 sites report using this module
- By e2thex on , updated
- This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.