Details
-
Bug
-
Resolution: Fixed
-
Medium
-
4.4.0, 4.3.4
-
None
-
None
Description
Currently, in Ibexa DXP v4 you can't store HTML tags inside a string attribute of a Custom Tag. All HTML tags are purged on save.
HTML tags are saved normally in v3.3.
Steps to reproduce
1. Clean installation of Ibexa DXP v4.3/4.4
2. Create a custom tag with a string attribute:
config/packages/ibexa.yaml
ibexa: system: admin_group: fieldtypes: ezrichtext: custom_tags: [ testtag ] toolbar: custom_tags_group: buttons: testtag: priority: 5 ibexa_fieldtype_richtext: custom_tags: testtag: template: 'custom_tags/testtag.html.twig' icon: '/bundles/ezplatformadminui/img/ez-icons.svg#information' attributes: string_with_html: type: string required: true
templates/custom_tags/testtag.html.twig
<h1>Test Tag</h1> <div> {{ params.string_with_html|raw }} </div>
3. Create a Content with a Richtext field and place newly created "Test Tag" custom tag inside, with string_with_html attribute set to:
<script>some_script</script>
And publish it.
4. Go back to previously published content, edit it and check saved value of the string_with_html attribute.
Result:
The value will be empty
Expected result:
<script>some_script</script>
Designs
Attachments
Issue Links
- relates to
-
IBX-5055 Using HTML Code in a Custom Tag attribute might end in "Validation of XML content failed" error
- Closed