function nodehierarchy_token_info in Node Hierarchy 7.4
Same name and namespace in other branches
- 7.2 nodehierarchy.tokens.inc \nodehierarchy_token_info()
Implements hook_token_info().
File
- ./
nodehierarchy.tokens.inc, line 11 - token integration functions for nodehierarchy.module
Code
function nodehierarchy_token_info() {
// Node tokens.
$info['types']['nodehierarchy'] = array(
'name' => t("Node Hierarchy"),
'description' => t("Tokens related to a node's hierarchy."),
'needs-data' => 'node',
);
$info['tokens']['node']['nodehierarchy'] = array(
'name' => t('Node Hierarchy'),
'description' => t("The source node for this current node's translation set."),
'type' => 'nodehierarchy',
);
$info['tokens']['nodehierarchy']['parent'] = array(
'name' => t('Parent Node'),
'description' => t('The primary parent of the node.'),
'type' => 'node',
);
return $info;
}