You are here

function nodewords_nodewords in Nodewords: D6 Meta Tags 5

Implementation of hook_nodewords().

File

./nodewords.module, line 48
Assign META tags to nodes, vocabularies, terms and pages.

Code

function nodewords_nodewords(&$tags, $op, $type = NULL, $ids = NULL) {
  switch ($op) {
    case 'list':
      return _nodewords_get_builtin_tags();
    case 'prepare':
      $settings = _nodewords_get_settings();
      foreach (_nodewords_get_builtin_tags() as $tag) {
        $function = _nodewords_get_builtin_function($tag, 'prepare');
        if (function_exists($function)) {
          $tags[$tag] = $function($type, $ids, isset($tags[$tag]) ? $tags[$tag] : '', $settings);
        }
      }
      break;
  }
}