简体   繁体   中英

Extra paragraphs (empty or not) when saving Text CE in CKEdtior (Typo3 vers 9 only)

Since I upgraded to Typo3 v9, all text CE saved in CKE Editor are "transformed" when displayed in FE, empty paragraphs are added between lines of text.

Line1
Line2

Becomes <p>Line1</p>
<p>&nbsp;</p>
<p>Line2</p>

Expected:
<p>Line1<br />Line2</p>

I found a few very similar posts/bug tracking but I cannot figure out how to solve this.

Nothing special like "flux" is used and it was working in Typo3 v8. Thanks in advance for your help. Joel

Usually the output would come from a fluid_styled_content template like TextMedia.html where it is rendered by the ViewHelper f:format.html

You might want to check the TypoScript object lib.parseFunc_RTE which transforms rich text from the database for frontend display (see https://docs.typo3.org/m/typo3/reference-typoscript/master/en-us/Functions/ )

Btw: it makes a difference if you press "Enter" (paragraph break) or "Shift+Enter" (break) in the rich text editor. Maybe that's what you are after?

When I installed a fresh Typo3 v9 instance everything was fine with CKE and FE output!

So I made additional test/research and finally discovered on 2 websites:

-rtehtmlarea extension was still active (we juste upgraded from 8->9) -RTE config herited from rtehtmlarea was still present in TS config

On the 1st site, desinstalling rtehtmlarea solved the problem. On the second one rtehtmlarea was not installed but obvioulsy the old config was a problem. Removing this config solved the problem as well !

Hope this can help other users.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM