diff options
Diffstat (limited to 'views/default/input/plaintext.php')
-rw-r--r-- | views/default/input/plaintext.php | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/views/default/input/plaintext.php b/views/default/input/plaintext.php index 04ff2f1f0..a0a8a3949 100644 --- a/views/default/input/plaintext.php +++ b/views/default/input/plaintext.php @@ -12,11 +12,17 @@ * */ -$class = $vars['class']; -if (!$class) { - $class = "elgg-input-textarea"; -} +$defaults = array( + 'class' => 'elgg-input-textarea' + 'disabled' => FALSE, +); +$value = $vars['value']; +unset($vars['value']); + +$attrs = array_merge($defaults, $vars); ?> -<textarea class="<?php echo $class; ?>" name="<?php echo $vars['internalname']; ?>" <?php if (isset($vars['internalid'])) echo "id=\"{$vars['internalid']}\""; ?> <?php if ($vars['disabled']) echo ' disabled="yes" '; ?> <?php echo $vars['js']; ?>><?php echo htmlentities($vars['value'], ENT_QUOTES, 'UTF-8'); ?></textarea>
\ No newline at end of file +<textarea <?php echo elgg_format_attributes($attrs); ?>> + <?php echo htmlentities($value, ENT_QUOTES, 'UTF-8'); ?> +</textarea> |