Bug #29246
closedHTMLparser_tags: fixAttrib.unset = 0 in fact unsets the value, too
100%
Description
According to http://typo3.org/documentation/document-library/references/doc_core_tsref/4.5.0/view/1/5/ the option "unset" for fixAttrib.[tag] is a boolean.
In the code of class.t3lib_parsehtml.php it is not. A strlen is used:
if (strlen($params['unset'])) {
unset($tagAttrib0[$attr]);
}
So if you give it any value (including 0) the tag will be removed. Either change the documentation or the code.
Updated by Chris topher over 13 years ago
- Subject changed from HTMLparser_tags - fixAttrib - unset is NOT a boolean to HTMLparser_tags: fixAttrib.unset = 0 in fact unsets the value, too
It does not make sense to unset the value when you write .unset = 0
. This behaviour should be fixed.
So I suggest not to change the documentation, but to fix the code.
Updated by Mr. Hudson about 13 years ago
Patch set 1 of change I608debf23280dd7d3816fe1ee05421cc88efc752 has been pushed to the review server.
It is available at http://review.typo3.org/4605
Updated by Markus Klein about 13 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100
Applied in changeset 5df562eed9e7016ae4a61b1df6f5b1bd50f42fac.
Updated by Markus Klein about 13 years ago
Hi Egbert,
the thing is fixed and will be included in the next releases.
Thanks for spotting this!
A forward from Jigal:
"Merged in 4.5 - 4.3
Thanks for the patch, good catch!"
Cheers
Markus
Updated by Chris topher about 13 years ago
- Category set to TypoScript
- Assignee set to Jigal van Hemert
- Target version set to 4.3.14
Updated by Riccardo De Contardi about 7 years ago
- Status changed from Resolved to Closed