You are here

function nodereference_count_token_values in Nodereference Count 6

Implementation of hook_token_values().

File

./nodereference_count.module, line 307
Defines a field type for counting the references to a node.

Code

function nodereference_count_token_values($type, $object = NULL) {
  if ($type == 'field') {
    $item = $object[0];
    $tokens['count'] = $item['value'];
    return $tokens;
  }
}