diff options
author | Marc Delisle <marc@infomarc.info> | 2014-03-27 20:45:05 +0400 |
---|---|---|
committer | Marc Delisle <marc@infomarc.info> | 2014-03-27 20:45:05 +0400 |
commit | a7ae3238e47dbc8e564dda0a749484d345e81ac2 (patch) | |
tree | 43602761e680beafb7c19cfb3398f2fcab9f59d9 /libraries | |
parent | a730cf9311dfe39849422eaa31a0d9a275eff242 (diff) | |
parent | 86707a63e48cdf3cbdb31b96db9dd72bb6442289 (diff) |
Merge pull request #1102 from maxday/420-cfg-CharEditing-textarea-for-structure-edit
#420 $cfg['CharEditing']='textarea' for structure edit
Diffstat (limited to 'libraries')
-rw-r--r-- | libraries/tbl_columns_definition_form.lib.php | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/libraries/tbl_columns_definition_form.lib.php b/libraries/tbl_columns_definition_form.lib.php index bcfa6122d8..130641162a 100644 --- a/libraries/tbl_columns_definition_form.lib.php +++ b/libraries/tbl_columns_definition_form.lib.php @@ -1100,12 +1100,21 @@ function PMA_getHtmlForColumnDefault($columnNumber, $ci, $ci_offset, $type_upper } $html .= '</select>'; $html .= '<br />'; - $html .= '<input type="text"' - . ' name="field_default_value[' . $columnNumber . ']" size="12"' - . ' value="' . (isset($columnMeta['DefaultValue']) - ? htmlspecialchars($columnMeta['DefaultValue']) - : '') . '"' - . ' class="textfield default_value" />'; + + $value = isset($columnMeta['DefaultValue']) ? htmlspecialchars($columnMeta['DefaultValue']) : ''; + if($GLOBALS['cfg']['CharEditing'] == 'textarea') { + $html .= '<textarea' + . ' name="field_default_value[' . $columnNumber . ']" cols="15"' + . ' class="textfield default_value">' + . $value + . '</textarea>'; + } + else { + $html .= '<input type="text"' + . ' name="field_default_value[' . $columnNumber . ']" size="12"' + . ' value="' . $value . '"' + . ' class="textfield default_value" />'; + } return $html; } |