Project

General

Profile

Actions

Bug #65393

closed

RTE wraps paragraphs in DIV tags in Chrome upon save

Added by Mario Rimann over 9 years ago. Updated over 8 years ago.

Status:
Rejected
Priority:
Should have
Assignee:
-
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
-
Start date:
2015-02-27
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

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

19-03-2015 08-58-34.png (21.7 KB) 19-03-2015 08-58-34.png Mario Rimann, 2015-03-19 09:00
Actions #1

Updated by Mario Rimann over 9 years ago

Chrome Version 40.0.2214.115
Firefox Version 35.0.1

The same also happens with TYPO3 CMS 6.2.10

Actions #2

Updated by Stanislas Rolland over 9 years ago

When copy-pasting, what paste behaviour are you using in user settings?

Actions #3

Updated by Mario Rimann over 9 years ago

See the attached user settings regarding the RTE - there's nothing configured IMO (e.g. using default settings).

Actions #4

Updated by Alexander Kontos over 9 years ago

Hi,

i can confirm that but unfortunately the behaviour comes from the HTMLArea itself.
Please go to
http://htmlarea.sourceforge.net/examples/core.html

Sorry we can't do anything here. Maybe you could try to get in contact with the programmer of the HTMLArea

Actions #5

Updated by Mathias Schreiber over 9 years ago

  • Status changed from New to Rejected
Actions #6

Updated by Wolfgang Hamster over 8 years ago

Hello,
is there already a solution?
This problem occurs more often...

Actions

Also available in: Atom PDF