Project

General

Profile

Actions

Bug #83960

closed

ckeditor HTMLparser_db: removeTags for unwanted tags doesn't work when tags are nested in <ul><li> or <ol><li>

Added by Claude Unterleitner about 6 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
-
Start date:
2018-02-19
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
8
PHP Version:
7.0
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

In my custom yaml ckeditor configuration I am removing unwanted tags with:
processing:
HTMLparser_db:
removeTags: pre,u,font,o:p,sdfield,strike,title

This works as expected when the tags are inside of p tags, but unfortunately not when nested in <ul><li> or <ol><li> tags.

(tested in TYPO3 8.7.10, PHP 7.0)

Actions #1

Updated by Riccardo De Contardi about 4 years ago

  • Status changed from New to Needs Feedback

Is this issue still present on version 9.5.14 or 10.4.0-dev?

I tried the following test:

1) Use the "full" preset for RTE; please note that this includes the EXT:rte_ckeditor/Configuration/RTE/Editor/Processing.yaml file that contains:

processing:
  HTMLparser_db:
    removeTags: [center, font, link, meta, o:p, sdfield, strike, style, title, u]

2) On a standard text I tried to add (using the source code view):

<p>lorem <strike>aaaa</strike><center>bbbbb</center><font>ggggggg</font></p>

<ol>
    <li>lorem <strike>aaaa</strike><center>bbbbb</center><font>ggggggg</font></li>
    <li>ipsum <strike>aaaa</strike><center>bbbbb</center><font>ggggggg</font></li>
</ol>

<p>lorem <strike>aaaa</strike><center>bbbbb</center><font>ggggggg</font></p>

<ul>
    <li>lorem <strike>aaaa</strike><center>bbbbb</center><font>ggggggg</font></li>
    <li>ipsum <strike>aaaa</strike><center>bbbbb</center><font>ggggggg</font></li>
</ul>

Results: after saving the final result is:

<p>lorem <s>aaaa</s></p>

<p>bbbbb</p>

<p>ggggggg</p>

<p>&nbsp;</p>

<ol>
    <li>lorem <s>aaaa</s>

    <p>bbbbb</p>
    ggggggg</li>
    <li>ipsum <s>aaaa</s>
    <p>bbbbb</p>
    ggggggg</li>
</ol>

<p>lorem <s>aaaa</s></p>

<p>bbbbb</p>

<p>ggggggg</p>

<p>&nbsp;</p>

<ul>
    <li>lorem <s>aaaa</s>

    <p>bbbbb</p>
    ggggggg</li>
    <li>ipsum <s>aaaa</s>
    <p>bbbbb</p>
    ggggggg</li>
</ul>
  • <strike> tag has been converted to <s>
  • <center> tag has been converted to <p>
  • <font> tag has been removed
  • it also added a couple of <p>&nbsp;</p> but I think it is another issue

Is if sufficient to consider this issue resolved or a different test is necessary? Am I missing something?

Actions #2

Updated by Benni Mack about 2 years ago

  • Status changed from Needs Feedback to Closed

Closing this issue due to lack on feedback. If you feel this is the wrong decision, let me know, and I will re-open the ticket.

Actions

Also available in: Atom PDF