FOF30\Form\Field\Text::getStatic PHP Метод

getStatic() публичный Метод

Get the rendering of this field type for static display, e.g. in a single item view (typically a "read" task).
С версии: 2.0
public getStatic ( ) : string
Результат string The field HTML
    public function getStatic()
    {
        if (is_array($this->value)) {
            $this->value = empty($this->value) ? '' : print_r($this->value, true);
        }
        if (isset($this->element['legacy'])) {
            return $this->getInput();
        }
        $class = $this->class ? ' class="' . $this->class . '"' : '';
        $empty_replacement = $this->element['empty_replacement'] ? (string) $this->element['empty_replacement'] : '';
        if (!empty($empty_replacement) && empty($this->value)) {
            $this->value = JText::_($empty_replacement);
        }
        return '<span id="' . $this->id . '" ' . $class . '>' . htmlspecialchars($this->value, ENT_COMPAT, 'UTF-8') . '</span>';
    }