Epic #82340: EXT:form - improve documentation
Documentation of "defaultValue"
Add the defaultValue option, supported by form viewhelper also to SingleSelect of ext:form, so one could define a preselected value of a select-field.
This issue was automatically created from https://github.com/TYPO3/TYPO3.CMS/pull/81
I will give an example here (after being rejected):
you add a select for countries, derived from static_info_tables.
you want e.g. germany or austria preselected in this dropdown.
if you have only the prependOption possibilites, which Ralf Zimmermann labels as 'implemented' you need to grab that values in your array of your field.
you need to remove them from there and add key and value to prependOption key and value.
furthermore you will destroy the ordering of the select, suddenly being germany the very first entry of the select. therefore you are breaking the navigation via keyboard through the options of the select, at least for these users, who want to fast-forward to the countries starting with 'G' ...