protected function generate_textarea($attributes) { $element = 'rtTextarea'; if (is_array($attributes)) { $html = '<textarea '; $html .= $this->processAttributes($element, $attributes); $html .= '>'; $html .= esc_html(isset($attributes['value']) ? $attributes['value'] : ''); $html .= '</textarea>'; if (isset($attributes['label'])) { if (isset($attributes['labelClass'])) { $html = $this->enclose_label($element, $html, $attributes['label'], $attributes['labelClass']); } else { $html = $this->enclose_label($element, $html, $attributes['label']); } } if (isset($attributes['show_desc']) && $attributes['show_desc']) { $html .= $this->generate_element_desc($attributes); } return $html; } else { throw new rtFormInvalidArgumentsException('attributes'); } }