function views_handler_field::is_value_empty

cis7 views_handler_field.inc views_handler_field::is_value_empty($value, $empty_zero, $no_skip_empty = TRUE)
cle7 views_handler_field.inc views_handler_field::is_value_empty($value, $empty_zero, $no_skip_empty = TRUE)
elmsmedia7 views_handler_field.inc views_handler_field::is_value_empty($value, $empty_zero, $no_skip_empty = TRUE)
icor7 views_handler_field.inc views_handler_field::is_value_empty($value, $empty_zero, $no_skip_empty = TRUE)
meedjum_blog7 views_handler_field.inc views_handler_field::is_value_empty($value, $empty_zero, $no_skip_empty = TRUE)
mooc7 views_handler_field.inc views_handler_field::is_value_empty($value, $empty_zero, $no_skip_empty = TRUE)

Checks if a field value is empty.

Parameters

$value: The field value.

bool $empty_zero: Whether or not this field is configured to consider 0 as empty.

bool $no_skip_empty: Whether or not to use empty() to check the value.

Return value

bool TRUE if the value is considered empty, FALSE otherwise.

2 calls to views_handler_field::is_value_empty()
views_handler_field::advanced_render in sites/all/modules/ulmus/views/handlers/views_handler_field.inc
Render a field using advanced settings.
views_handler_field::render_text in sites/all/modules/ulmus/views/handlers/views_handler_field.inc
Perform an advanced text render for the item.

File

sites/all/modules/ulmus/views/handlers/views_handler_field.inc, line 1107
@todo.

Class

views_handler_field
Base field handler that has no options and renders an unformatted field.

Code

function is_value_empty($value, $empty_zero, $no_skip_empty = TRUE) {
  if (!isset($value)) {
    $empty = TRUE;
  }
  else {
    $empty = ($empty_zero || ($value !== 0 && $value !== '0'));
  }

  if ($no_skip_empty) {
    $empty = empty($value) && $empty;
  }
  return $empty;
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.