You are here

function hosting_site_handler_field_status::render in Hosting 7.4

Same name and namespace in other branches
  1. 7.3 site/includes/views/handlers/hosting_site_handler_field_status.inc \hosting_site_handler_field_status::render()

Render the field.

Parameters

array $values: The values retrieved from the database.

Overrides views_handler_field::render

1 method overrides hosting_site_handler_field_status::render()
hosting_package_handler_field_status::render in package/includes/views/handlers/hosting_package_handler_field_status.inc
Render the field.

File

site/includes/views/handlers/hosting_site_handler_field_status.inc, line 9

Class

hosting_site_handler_field_status
A handler for the Site status field.

Code

function render($values) {
  $value = $values->{$this->field_alias};
  $output = _hosting_site_status($value);
  switch ($this->options['status_mode']) {
    case 'image':
      return "<span class='hosting-status hosting-status-icon'></span>";
    case 'text_image':
      return "<span class='hosting-status'>{$output}</span>";
    case 'class':
      return _hosting_site_list_class($value, $values->{$this->aliases['verified']});
  }
  return $output;
}