You are here

public function Formatter::xhtml in Forena Reports 8

Format data as XHTML, escaping output.

Parameters

$value: The value to format.

$format_string: The name of the input format to run against

Return value

string

File

src/FrxPlugin/FieldFormatter/Formatter.php, line 151
contains various methods for extending report formating, layout, transformation and design.

Class

Formatter
Formatter for common drupal fields.

Namespace

Drupal\forena\FrxPlugin\FieldFormatter

Code

public function xhtml($value, $format_string) {
  if ($value) {
    $value = html_entity_decode($value, ENT_QUOTES, 'UTF-8');
    if ($format_string && filter_format_exists($format_string)) {
      $value = check_markup($value, $format_string);
    }
  }
  return $value;
}