Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to get rid of the line break which Confluence is adding when editing.

Paula Quint October 23, 2013

I have created a template that contains a table holding partly prefixed texts. Users have to fill in texts themselves when creating a page. While testing this I noticed that Confluence is adding a <br/> after a text added in the editing mode. This <br/> causes a white line in the export to Word. This <br/> is not wanted.

Example:

The template says:

<td>
<p>
<em>1)</em>
</p>
</td>

The created Page based on this template says:

<td>
<em>1) Dizzy - Tommy Row<br/>
</em>
</td>

Can anybody explain why there is the <br/> and how can I get rid of it!!!

Thanks in advance. By the way, this ia all happening in Confluence 5.1.5.

Best regards,

Paula Quint

5 answers

1 accepted

0 votes
Answer accepted
Paula Quint October 24, 2013

Thanks again! I just discovered that using Italic <em></em> in the template is causing the <br/> when creating/editing a page based on this template. So now I skipped all the Italic in the template and add them when creating/editing. This gives me the result in Word I want!! :-)

2 votes
Matthew J. Horn
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 23, 2013

I don't remember if this happens when creating a template, but Confluence inserts hidden tags all over the place when you work in the GUI editor. If you can (and again, I don't remember if template creation allows this), use the Source Editor plugin to get in there and remove extraneous tags.

Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 23, 2013

The source editor does work in template creation.

Stephen Gilson
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 29, 2013

+1 Thanks for the help

0 votes
Steffen Heller
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 24, 2013

I have had the same experience as Matthew: There are lots of hidden tags and there is no way controlling it.

My typical problem are <p> within table headers.They are sometimes...

  • ...there: <th><p>text</p></th>
  • ...and sometimes not: <th>text</th>

The result is that the font formatting is different in Confluence and the height of the table header cell is different in PDF.

My "solution" is to ignore the difference in Confluence but to define CSS styles that make the header look the same in PDF.

Matthew J. Horn
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 29, 2013

Yup, I find myself going into the source editor on really complicated pages (lists within lists, macros within sub-lists). The most common thing I remove is extra <p> tags from list items and extraneous <span> tags. Requires a bit of manual work, but cleaning up a page in the source is so much easier than wrestling with the GUI's "generous" tag insertion.

0 votes
Paula Quint October 24, 2013

Thanks for your answers, but I allready deleted alle the <br/>'s in the template via the source editor. But whenever I create a new page based on this template and I add texts the <br/>'s show up again after saving the page and causes whitelines in Word when I export the page. The idea of deleting all the <br/>'s everytime I create a page based on this template makes me unhappy! :-(

Any other ideas?

0 votes
Steffen Heller
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 23, 2013

I can't say why it is there. But have you tried to simply delete it? That is what I do with it.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events