Bug #65393
closedRTE wraps paragraphs in DIV tags in Chrome upon save
0%
Description
Hi
I'm adding three lines of text in an empty RTE (entering by hand, no copy-pasting):
foo bar baz
When I switch to the HTML-view within RTE before saving the content element, I see the following:
<p>foo</p><p>bar</p><p>baz</p>
Which I think is OK
When I then save the content element and again have a look at the HTML-view within the RTE, it shows this:
<p>foo</p> <p>bar</p> <p>baz</p>
Still everything OK, outcome as expected.
But when I copy-paste the same three lines from Notepad++ as pure Text (no styling) to the empty RTE I see the following text:
foo bar baz
Switching to the HTML-view within the RTE shows:
<div>foo</div><div>bar</div><div>baz</div>
And finally saving the CE results in the following HTML-view:
<div><p>foo</p></div> <div><p>bar</p></div> <div><p>baz</p></div>
I first thought, it could be depending on the line-endings configured/used in Notepad++ at first (it was CR/LF), but switching from Windows to Unix-Line-Endings in the text-editor (LF only) didn't solve the issue!
So what I see is that the RTE in Chrome behaves differently, depending on whether someone enters text into the RTE directly or copy-pastes the "same" content from another editor.
Strange thing is, that the same procedure as outlined above works in Firefox! Difference in Firefox is, that the copy-pasted text is interpreted as
<p>foo<br />bar<br />baz</p>
Which well, is not exactly identical to entering the text instead of copy-pasting - but it didn't matter so far for our customers. But as they start using Chrome more and more, the above mentioned issue would be nice to get fixed.
Tested on TYPO3 CMS v6.2.9
Files