How to remove the BR added to all content blocks.

Posted by Community Admin on 04-Aug-2018 18:06

How to remove the BR added to all content blocks.

All Replies

Posted by Community Admin on 04-Jun-2012 00:00

Apparently Sitefinity adds a <br /> to the end of each of my content blocks. I can view the html of the content that I put in the content block and there is nothing. When it renders on the page it has a <br />. All of my content blocks do this.

So I have two questions:
1. Why?
2. How do I remove it server-side?

While on the topic, I have another question where it seems that other items are added to my code when it is renderd (http://www.sitefinity.com/devnet/forums/sitefinity/developing-with-sitefinity/how-to-remove-the-zero-space-character-that-repeaters-listviews-generate.aspx) Is there a generic way to get around all of these type issues? Does Sitefinity have some filter it runs everything through and adds random html entities to?

Posted by Community Admin on 04-Jun-2012 00:00

Upgrade to 5.0, it's fixed...or hack it out in your version with CSS or jQuery.  Sorry if those solutions aren't optimal... :/

...as to why, it was probably just either a bad idea at styling or left in by accident.  Maybe they didn't test turning it off (who knows)...its in there so the social widget would appear after the content, but if you dont use the social widgets, then its still there

I believe in 5 it's properly all hidden (until enabled) and uses divs nor a <br/> (I think)

Posted by Community Admin on 05-Jun-2012 00:00

Unfortunately I am already on 5.0. I did end up removing them with jQuery but it felt dirty.

Posted by Community Admin on 05-Jun-2012 00:00

Which version, 5.0 or 5.0 SP1

http://www.sitefinity.com/devnet/release-notes/details/sitefinity-5-0-sp1.aspx
"Inserting unneeded BR tags in the end of the content items"

Posted by Community Admin on 05-Jun-2012 00:00

I'm not sure. I assume just 5.0. Here is my meta tag:
<meta name="Generator" content="Sitefinity 5.0.2523.0 SE" /> 

Posted by Community Admin on 05-Jun-2012 00:00

There we go!...that's 5.0 :)

Ok, so backup your DB, project, and run the SP1 upgrade and you're golden

(SP1 is 5.0.2800, couple hotfixes past that too, so probably a slightly higher version#)

This thread is closed