function taxonomy_vocabulary_get_names

Get names for all taxonomy vocabularies.

Return value

An associative array of objects keyed by vocabulary machine name with information about taxonomy vocabularies. Each object has properties:

  • name: The vocabulary name.
  • machine_name: The machine name.
  • vid: The vocabulary ID.
17 calls to taxonomy_vocabulary_get_names()
forum_entity_info_alter in drupal/core/modules/forum/forum.module
Implements hook_entity_info_alter().
NodeTermData::buildOptionsForm in drupal/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/relationship/NodeTermData.php
Default options form that provides the label widget that all fields should have.
NodeTermData::init in drupal/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/relationship/NodeTermData.php
Init handler to let relationships live on tables other than the table they operate on.
TaxonomyIndexTid::buildExtraOptionsForm in drupal/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/filter/TaxonomyIndexTid.php
Provide a form for setting options.
TaxonomyIndexTid::buildOptionsForm in drupal/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/field/TaxonomyIndexTid.php
Provide "link to term" option.

... See full list

1 string reference to 'taxonomy_vocabulary_get_names'
VocabularyStorageController::resetCache in drupal/core/modules/taxonomy/lib/Drupal/taxonomy/VocabularyStorageController.php
Overrides Drupal\Core\Entity\DrupalDatabaseStorageController::resetCache().

File

drupal/core/modules/taxonomy/taxonomy.module, line 636
Enables the organization of content into categories.

Code

function taxonomy_vocabulary_get_names() {
  $names =& drupal_static(__FUNCTION__);
  if (!isset($names)) {
    $names = db_query('SELECT name, machine_name, vid FROM {taxonomy_vocabulary}')
      ->fetchAllAssoc('machine_name');
  }
  return $names;
}