Actions
Bug #58310
closedrtehtmlarea "remove format" eats too much (Patch included)
Status:
Closed
Priority:
Must have
Assignee:
-
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
-
Start date:
2014-04-29
Due date:
% Done:
100%
Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:
Description
The remove format function w/ msword selected removes too much content. This seems to affect all Versions of TYPO3 CMS 4.7 to 6.2.1!
File typo3/sysext/rtehtmlarea/htmlarea/plugins/RemoveFormat/remove-format.js, line 244-246:
// Remove unwanted tags and their contents: style, title html = html.replace(/<style[^>]*>.*<\/style[^>]*>/gi, ""). replace(/<title[^>]*>.*<\/title[^>]*>/gi, "");
This removes too much content if more than one <style> block is found inside the content.
Patch:
// Remove unwanted tags and their contents: style, title html = html.replace(/<style[^>]*>.*?<\/style[^>]*>/gi, ""). replace(/<title[^>]*>.*<\/title[^>]*>/gi, "");
(Added a Questionmark in the style regexp.)
Updated by Gerrit Code Review over 10 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/30223
Updated by Stanislas Rolland over 10 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 4a3e526a7587e221e5af8215e0308e09601a0d5c.
Actions