2

Whenever I add any content in wiki page, one br tag gets appends to the end of the content before closing tag,

For e.g.

If I had header text and click on edit HTML source, it looks like

<h1>Hello World<br/></h1>

Is it a bug in SharePoint?

enter image description here

4

No, it's not a SharePoint bug. I faced the same behavior when I enabled a google extension like Grammarly, it considers the cursor place as a line break <br> tag.

For Example,

When you add <h1>Hello World</h1> in Source HTML

  • If you leave the cursor at the end of the word world then clicked OK, in the next Edit HTML source, you will note that a line break <br> tag has been added inside the <H1> tag. as <h1>Hello World</br></h1>

  • Now try to add the cursor outside <h1> tag, then click OK, and go back to edit the source again, you will note that a line break <br> tag has been added after the <h1>Hello World</h1></br>

So try to disable any add-ons/extension during editing the HTML Source and you will not face this issue!

0

Add your code as a single line or remove any indentation. The content editor will format these elements after saving them and will not create additional tags or characters.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.