-
-
Notifications
You must be signed in to change notification settings - Fork 23
Open
Description
Describe the bug
Consider this template and firstName
having the content M<a
:
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
xmlns:pdf="http://typo3.org/ns/Bithost/Pdfviewhelpers/ViewHelpers"
data-namespace-typo3-fluid="true"
>
<pdf:document title="TestCertificate" outputPath="{outputPath}" outputDestination="F">
<pdf:page>
<pdf:html>{firstName}</pdf:html>
<pdf:text>{firstName}</pdf:text>
</pdf:page>
</pdf:document>
</html>
This results in a PDF, which only contains an M
because the <
character in the variable breaks the output.
The reason is that the escaping configuration of the viewhelpers is wrong. Escaping must only be turned off for content viewhelpers not dealing with HTML.
Environment
TYPO3 version(s): v12
pdfviewhelpers version: 3.1.1
Expected behavior
The output should contain the variable's content correctly within the HTML and the TEXT block.
Possible solution
Configure escaping of output and children correctly in viewhelpers.
Metadata
Metadata
Assignees
Labels
No labels