Bug #81577
closedf:format.html / parseFunc removes spaces between tags
100%
Description
If italic text is followed by bold text the space between the two strings is removed.
This bug can be reproduced on a vanilla TYPO3 8.7.1 installation
<f:format.html><p><strong>Strong</strong> <em>Italic</em></p></f:format.html>
When rendering this it will show
Italic*Strong*
Updated by Christopher Zechendorf over 7 years ago
Sorry. Formatting didn't pan out.
It outputs:
<p><strong>Strong</strong><em>Italic</em></p>
Updated by Christopher Zechendorf over 7 years ago
- Subject changed from parseFunc removes spaces between tags to f:format.html / parseFunc removes spaces between tags
- Assignee deleted (
Christopher Zechendorf) - Estimated time deleted (
2.00 h) - Complexity deleted (
medium)
Updated by Christopher Zechendorf over 7 years ago
Further research resulted in this insight:
It has nothing to do with format.html - the result of a fluid_styled_content - Content-Element will be cleaned in a way that all whitespace between tags will be removed. Only newlines are kept.
<strong>Strong</strong> <em>em</em>
Will also be reduced to.
<strong>Strong</strong><em>em</em>
This does not happen when a regular FLUIDTEMPLATE TS Object is generated.
This means the behavior either happens somewhere in fluid_styled content or in the content object itself. Using css_styled_content will not result in this behavior.
Updated by Christopher Zechendorf over 7 years ago
- % Done changed from 0 to 100
And I've found the reason.
The Layout in fluid_styled_content
typo3/sysext/fluid_styled_content/Resources/Private/Layouts/Default.html
encapses everything in
<f:spaceless>
which results in the behavior.
So this is not a bug but a feature (...i guess).
Updated by Riccardo De Contardi over 7 years ago
- Target version deleted (
next-patchlevel)
I close this issue as the behavior is intended - see https://fluidtypo3.org/viewhelpers/fluid/master/SpacelessViewHelper.html
If you think that this is the wrong decision please reopen it or open a new issue with a reference to this one. Thank you.
Updated by Riccardo De Contardi over 7 years ago
- Status changed from New to Closed
Updated by Mona Muzaffar over 7 years ago
- Related to Bug #81616: TYPO3 generated HTML-output strips off whitespaces/linebreaks between tags. added