【问题标题】:How to get the taxonomy terms related to a content type in drupal如何在drupal中获取与内容类型相关的分类术语
【发布时间】:2014-01-29 15:56:30
【问题描述】:

我正在使用field_info_instances() 获取内容类型的 cck 字段列表

$my_fields = field_info_instances("node", "my_custom_content_type");

我想要的是获取与内容类型相关的分类术语。如何做到这一点?

【问题讨论】:

    标签: drupal drupal-7


    【解决方案1】:

    您可以使用 Drupal API for taxonomy 获取此信息:

    taxonomy_get_vocabularies($type = 'my_custom_content_type');
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2011-05-25
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-04-26
      • 2022-06-23
      • 2014-09-06
      相关资源
      最近更新 更多