Bug #95189
closedPadding with TypoScript strPad does not work correctly with multibyte characters
100%
Description
When using strings with multibyte characters, the strings are not padded correctly with TypoScript strPad.
The result is the same as with PHP str_pad() which also does not work correctly with multibyte characters (as str_pad() is used under the hood).
Example: Reproduce¶
TypoScript
page > page = PAGE page.30 = TEXT page.30.value = hellö page.30.value.strPad { length = 10 padWith = * type = both } page.40 = TEXT page.40.value = <br/> page.50 = TEXT page.50.value = hello page.50.value.strPad { length = 10 padWith = * type = both }
Result¶
**hellö** **hello***
Expected result¶
**hellö*** **hello***
Versions¶
- TYPO3 10.4 (latest)
- TYPO3 master (11-dev)
Updated by Sybille Peters about 3 years ago
- Related to Bug #95190: Padding with Fluid ViewHelper format.padding does not work correctly with multibyte strings added
Updated by Gerrit Code Review about 3 years ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/71032
Updated by Gerrit Code Review about 3 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/71032
Updated by Gerrit Code Review about 3 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/71032
Updated by Gerrit Code Review about 3 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/71032
Updated by Gerrit Code Review about 3 years ago
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/71032
Updated by Sybille Peters about 3 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset e27614cda1e21e539bec35120f74948b6184bc5e.
Updated by Gerrit Code Review about 3 years ago
- Status changed from Closed to Under Review
Patch set 1 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/71623
Updated by Sybille Peters about 3 years ago
- Status changed from Under Review to Resolved
Applied in changeset 641aa36c95aa1fc9c74d66599c2e3aca7c5676fa.