1.20.x token.inc token_get_module($token_type, $token_name)

Return the module responsible for a token.

Parameters

string $token_type: The token type.

string $token_name: The token name.

Return value

mixed: The module name that provides the token or NULL if the value does not exist.

File

includes/token.inc, line 350
Backdrop placeholder/token replacement system.

Code

function token_get_module($token_type, $token_name) {
  $token_info = token_get_info($token_type, $token_name);
  return isset($token_info['module']) ? $token_info['module'] : NULL;
}