Bug #89161
closedSuggest Wizard for type=group inserts prepared labels as HTML content
100%
Description
Problem¶
When applying a record provided by the Suggest wizard within a database field of type=group, HTML gets applied together with the shortened label (if the record title is too long and gets shortened).
This happens because the Suggest wizard provides prepared labels. If a record is longer than the maximum length defined in the backend user settings, the label will be wrapped within a <span>
element. As the label is applied as <option>
within the appropriate <select>
field of the database field in the form, the plain HTML will be printed.
Repro¶
1. Create a page with a long page title
2. Go to any page and search in field "content_from_pid" for the page
3. Apply the suggestion from Suggest wizard
4. The <select> should now contain something like <span title="This is a pretty long page title which was created for testing only">This is a pretty long page...</span>
Expected behaviour¶
The <select>
should contain an option with content "This is a pretty long page..." only.
Problem could be reproduced with TYPO3 9.5 and current master (not tested with 8.7).