I can't get YUI Rich Text Editor to properly make line breaks in my text. It seems like it should be using p tags instead of br tags.

Is this is a known issue, have I done something wrong, or is this something that should be addressed within the module itself?

Comments

jeffcd’s picture

Status: Active » Closed (fixed)

The dev snapshot for 6.x now has br to p translation (primitive, but it's a start. Not sure if I'll get to 5.x.

muhleder’s picture

Is it not possible to put an event listener in the yui_editor.js to listen for 'enter' keypress, and insert <p></p> when it happens? And maybe a listener for 'shift-enter' to put <br/> in?

muhleder’s picture

Hmm.. just been having a play with my 5.x installation of this, and I need to enable <p>tags as allowed in the Drupal input filter. Once I do that the YUI editor turns double breaks into paragraphs as you'd expect.

In fact you need to enable all the tags you might want to let through, here's the list I had to add.

<h1><h2><h3><h4><h5><h6><img> <br> <p>