When there is no content in the body of a node that is using the line break filter, the filter adds a

<br />

to the node content. This adds undesired space that cannot be removed even with css (it is pushing down some items that come after the body).

CommentFileSizeAuthor
#3 filter_no_break_on_empty.patch.txt712 bytesheine

Comments

karens’s picture

Priority: Normal » Minor

Changing status, meant to do this the first time :-)

yvelle’s picture

The problem goes away when i comment out:
$format = filter_resolve_format($format);
from:
function check_markup(

But not when you comment out any other line. I'm going to keep playing with this to see what I can find.

heine’s picture

Status: Active » Needs review
StatusFileSize
new712 bytes

Added a check for empty input.

heine’s picture

Status: Needs review » Needs work

doesn't even solve the issue

ricabrantes’s picture

Version: x.y.z » 7.x-dev

Bug active?? moving d7.x

sun’s picture

Title: Break filter adds break to empty node » Line break filter adds a BR to empty text
sun’s picture

Status: Needs work » Closed (won't fix)

I can't replicate this bug in HEAD.

jaysadie’s picture

I'm having the same problem. I'm using CKEditor, so not sure if that has anything to do with it.

heldermarketing’s picture

I have an almost similair issue.

When I add 1 break in the content. There are 2 breaks being outputted into the content. When I look into the node/block content in the database it only has 1 break tag. So the problem must have to do something with the filters or preprocessors.

This issue is on Drupal 6. Probably similair problem as on 7.