C3RC1: Forms - textarea - standard value can't be deleted #4722
Comments
The default value should be ignored by the textarea widget. |
Same behaviour in 2.11.4 on demo.contao.org Define a default value for the textfield. Save entry. Now change the type of the FormItem to textarea. But the default value is still displayed in the frontend. |
Thanks for checking, I have moved the ticket to the 2.11.6 milestone. |
Fixed in 4170caf. |
Please add type "select" to the list. Its the same behaviour. ;-) |
Maybe we should work with a positive list instead of a negative list. AFAIK, default values are only required for text and password fields, aren't they? |
As i can see in the palette entry, there is only text and hidden : https://github.com/contao/core/blob/2.11.5/system/modules/backend/dca/tl_form_field.php#L117 Password formfield did not use the default value : https://github.com/contao/core/blob/2.11.5/system/modules/frontend/FormPassword.php#L143 I think, it will be autofilled by browser. I prefer a whitelist, which can be enhanced by $GLOBALS ? Maybe ;-) |
Changed in 83e4789. The routine checks the palette, which is kind of a built-in whitelist :) |
If a textfield with a defined standard value is converted into a textarea the standard value stays there and can't be deleted.
You have to change it back into a textfield, erase the standard value, save and reconvet into a textarea.
(Not sure if it was the same behavior with Contao 2.)
The text was updated successfully, but these errors were encountered: