WYSIWYG editor leaves blank line

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
lurch
Regular
Posts: 9
Joined: Fri Jan 17, 2014 9:58 pm

WYSIWYG editor leaves blank line

Post by lurch » Sat Jan 18, 2014 2:15 pm

When using the WYSIWYG editor after pressing return it goes down 2 lines ie

line 1

line 2

i've looked for anything that could be causing this as I assume it's something simple but I just can't find it.

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: WYSIWYG editor leaves blank line

Post by Timbalu » Sat Jan 18, 2014 2:57 pm

Do you really mean WYSIWYG-Editor enabled in personal preferences?
I am not sure what you mean to happen actually ... but first read this about S9y WYSIWYG Editors
http://board.s9y.org/viewtopic.php?f=4&t=19354 (that might help)
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

lurch
Regular
Posts: 9
Joined: Fri Jan 17, 2014 9:58 pm

Re: WYSIWYG editor leaves blank line

Post by lurch » Sat Jan 18, 2014 3:15 pm

yes, i've just install serendipity_event_ckeditor and it's doing the same thing

Image

evert time i press 'return' it goes down 2 lines

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: WYSIWYG editor leaves blank line

Post by Timbalu » Sat Jan 18, 2014 3:34 pm

You mean in the editor itself - in wysiwyg-mode, right?
This is the normal usage of <p></p> = paragraph as the default newline (nl) replacer. (Has nothing to do with our nl2br (read nl-to-br, not two!) plugin though.)
See http://ckeditor.com/demo
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

lurch
Regular
Posts: 9
Joined: Fri Jan 17, 2014 9:58 pm

Re: WYSIWYG editor leaves blank line

Post by lurch » Sat Jan 18, 2014 3:41 pm

yes that's right, is there anyway i can change this behavior?

i tried adding

Code: Select all

CKEDITOR.replace( 'textarea_id',
	{
		enterMode : CKEDITOR.ENTER_DIV
	});
to config.js but that didn't work

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: WYSIWYG editor leaves blank line

Post by Timbalu » Sat Jan 18, 2014 3:58 pm

Yes and No. Since this is the WWW, you can tell the p tag to behave differently by CSS. But that would mean to change ckeditor CSS, Serendipity CSS and your templates CSS. Everyone used to this paragraph behaviour would moun and this is a fight against windmills. :wink:

But if you promise not to tell anbody, there is an (internal) option - open the custom cke_config.js (Line ~76) and set

Code: Select all

config.enterMode = CKEDITOR.ENTER_BR;
:lol:
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

User avatar
garvinhicking
Core Developer
Posts: 30020
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: WYSIWYG editor leaves blank line

Post by garvinhicking » Sat Jan 18, 2014 4:01 pm

Hit Shift+Enter. :)
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/

User avatar
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: WYSIWYG editor leaves blank line

Post by Timbalu » Sat Jan 18, 2014 4:06 pm

I'm impressed!!!!!!! :)

Edit: I added a cheatsheet plugin to ckeditor 3.2.0+, which will help to find hidden gems like this!
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian

Post Reply