function taxonomy_field_is_empty

taxonomy_field_is_empty($item, $field)

Implements hook_field_is_empty().

File

modules/taxonomy/taxonomy.module, line 1561
Enables the organization of content into categories.

Code

function taxonomy_field_is_empty($item, $field) {
  if (!is_array($item) || (empty($item['tid']) && (string) $item['tid'] !== '0')) {
    return TRUE;
  }
  return FALSE;
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!taxonomy!taxonomy.module/function/taxonomy_field_is_empty/7.x