Ozair Patel
Ozair Patel

Reputation: 1926

CKEDITOR On Enter Do <br> But keep on one line

Currently in CKEDITOR when I type "Hello

World!"

The source is

<p>Hello</p>

<p>&nbsp;</p>

<p>World!</p>

<p>&nbsp;</p>

I've looked almost everywhere and what I'd like is

"Hello

World!"

to render

<p>Hello<br>World!</p>

or

<p>Hello</p><br><p>World!</p>

Upvotes: 0

Views: 1225

Answers (2)

Spons
Spons

Reputation: 1591

The shift + enter key is indeed what your looking for like chrisLTD suggested. But if you like to configure it.

Here you can find a explanation of the enter key configurations and how to configure. http://ckeditor.com/ckeditor_4.1rc/samples/plugins/enterkey/enterkey.html

CKEDITOR.replace( 'textarea_id', {
enterMode: CKEDITOR.ENTER_BR
});

Upvotes: 1

ChrisLTD
ChrisLTD

Reputation: 433

Try holding down shift while pressing enter.

More info on the CKEditor forum's here.

Upvotes: 0

Related Questions