Bug #62967

xhtml cleaning broken for javascript

Added by Nicole Cordes over 5 years ago. Updated over 1 year ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
-
Target version:
-
Start date:
2014-11-15
Due date:
% Done:

100%

TYPO3 Version:
4.5
PHP Version:
Tags:
Complexity:
Is Regression:
Yes
Sprint Focus:

Description

Due to commit https://review.typo3.org/#/c/30240/ the xhtml_cleaning for javascript gets broken as the comments were removed and javascript is parsed in a wrong way. A solution would be to exclude CDATA-code from parsing.

As the xhtml_cleaning should be removed in master anyway, the patch only applies to 6.2 and 4.5!


Related issues

Related to TYPO3 Core - Bug #55457: RTE on first new IRRE record keeps loading in IE Closed 2014-01-30

Associated revisions

Revision e2873344 (diff)
Added by Nicole Cordes over 5 years ago

[BUGFIX] Exclude CDATA from t3lib_parsehtml->XHTML_clean

Due to commit https://review.typo3.org/#/c/30240/ the comments from
javascript is removed and now the javascript is parsed with
config.xhtml_cleaning = all. This patch prevents any CDATA content from
being parsed.

Resolves: #62967
Releases: master, 6.2, 4.5
Change-Id: Ib024c5c8f2b056e47d9222b9767b7a5e6923af8c
Reviewed-on: http://review.typo3.org/34207
Reviewed-by: Nicole Cordes <>
Tested-by: Nicole Cordes <>
Reviewed-by: Oliver Hader <>
Tested-by: Oliver Hader <>

Revision aa95a4f7 (diff)
Added by Nicole Cordes over 5 years ago

[BUGFIX] Exclude CDATA from t3lib_parsehtml->XHTML_clean

Due to commit https://review.typo3.org/#/c/30240/ the comments from
javascript is removed and now the javascript is parsed with
config.xhtml_cleaning = all. This patch prevents any CDATA content from
being parsed.

Resolves: #62967
Releases: master, 6.2, 4.5
Change-Id: Ib024c5c8f2b056e47d9222b9767b7a5e6923af8c
Reviewed-on: http://review.typo3.org/34192
Reviewed-by: Oliver Hader <>
Tested-by: Oliver Hader <>

Revision 5c267d20 (diff)
Added by Nicole Cordes over 5 years ago

[BUGFIX] Exclude CDATA from t3lib_parsehtml->XHTML_clean

Due to commit https://review.typo3.org/#/c/30240/ the comments from
javascript is removed and now the javascript is parsed with
config.xhtml_cleaning = all. This patch prevents any CDATA content from
being parsed.

Resolves: #62967
Releases: master, 6.2, 4.5
Change-Id: Ib024c5c8f2b056e47d9222b9767b7a5e6923af8c
Reviewed-on: http://review.typo3.org/35039
Reviewed-by: Nicole Cordes <>
Tested-by: Nicole Cordes <>
Reviewed-by: Oliver Hader <>
Tested-by: Oliver Hader <>

History

#1 Updated by Markus Klein over 5 years ago

I'm sure this is a duplicate... I read this somewhere else recently.
I also added the relation to the ticket.

#2 Updated by Gerrit Code Review over 5 years ago

  • Status changed from New to Under Review

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/34192

#3 Updated by Oliver Hader over 5 years ago

TypoScript to reproduce

page.jsInline {
  123 = TEXT
  123.value = console.log('<hello world>');
}

config.xhtml_cleaning = all
config.removeDefaultJS = 0

The frontend rendering will produce

console.log('<hello world="">');

instead of just
console.log('<hello world>');

#4 Updated by Gerrit Code Review over 5 years ago

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/34207

#5 Updated by Gerrit Code Review over 5 years ago

Patch set 2 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/34192

#6 Updated by Nicole Cordes over 5 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#7 Updated by Gerrit Code Review over 5 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch TYPO3_4-5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/35039

#8 Updated by Nicole Cordes over 5 years ago

  • Status changed from Under Review to Resolved

#9 Updated by Benni Mack over 1 year ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF