You are here

public function DrupalDefaultMetaTag::getValue in Metatag 7

Get the string value of this meta tag.

Return value

string The value of this meta tag.

Overrides DrupalMetaTagInterface::getValue

1 call to DrupalDefaultMetaTag::getValue()
DrupalDefaultMetaTag::getElement in ./metatag.inc
Get the HTML tag for this meta tag.
3 methods override DrupalDefaultMetaTag::getValue()
DrupalDateIntervalMetaTag::getValue in ./metatag.inc
Get the string value of this meta tag.
DrupalListMetaTag::getValue in ./metatag.inc
Get the string value of this meta tag.
DrupalTextMetaTag::getValue in ./metatag.inc
Get the string value of this meta tag.

File

./metatag.inc, line 138
Metatag primary classes.

Class

DrupalDefaultMetaTag
The default meta tag class from which all others inherit.

Code

public function getValue(array $options = array()) {
  $value = $this
    ->tidyValue($this->data['value']);

  // Translate the final output string prior to output. Use the
  // 'output' i18n_string object type, and pass along the meta tag's
  // options as the context so it can be handled appropriately.
  $value = metatag_translate_metatag($value, $this->info['name'], $options, NULL, TRUE);
  return $this
    ->truncate($this
    ->tidyValue($this->data['value']));
}