Opened 3 years ago

Closed 3 years ago

#14668 closed Bug (expired)

CKEditor Lost \r\n

Reported by: ffvolkmargrimm Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: Cc:

Description

Hi,

For historical reasons the textarea element returns an \n by reading the value, if setting the textarea content with an \r\n inside. Is there any possiblity to prevent the CKEditor to do this? Just like the lineBreakChars of the CKEDITOR.htmlWriter-Modul?

Thanks

Change History (2)

comment:1 Changed 3 years ago by Jakub Ś

Status: newpending
Version: 4.5.10 (GitHub - master)

The retuned for simplicity has \n set. This is the default setting.

You can either try using getData().replace( /\n/, '\r\n' ); or configuring htmlWriter to return \r\n - http://docs.ckeditor.com/#!/api/CKEDITOR.htmlWriter-property-lineBreakChars. The htmlWriter takes care of data returned from editor so changing its settings should do the trick.

Does this answer your question?

comment:2 Changed 3 years ago by Jakub Ś

Resolution: expired
Status: pendingclosed
Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy